Start window 64 bit explorer.exe from 32 bit installer - windows

My Question: I need to kill the explore.exe and start the explorer.exe on 64 bit machine using 32 bit installer. If i created the batch file and double click on the batch file then it work fine but when i integrate in installer, it failed.
I execute below mentioned command but not able to succeed.
When i executed the below command, it kill the task bar and create the explorer.exe but not shown the taskbar.
taskkill /F /IM explorer.exe
cd C:\Windows\Sysnative
start /B explorer.exe
When i executed the below command, it kill the task bar and create the explorer.exe but shown the taskbar and hang the installer.
taskkill /F /IM explorer.exe
%systemroot%\sysnative\cmd.exe /c start /B explorer.exe
Please suggest me how solve this problem.
Thanks in advance.

Related

Closing only a window of an active application via .bat file

I am looking for a solution to close a window and leave the .exe running.
The .bat file:
#echo off
TITLE Bejelentkezes ujrainditasa
TASKKILL /F /im eszig-eid.exe
TASKKILL /F /im eszig-cmu.exe
start /d "C:\Program Files (x86)\ESZEMELYI\eSzemelyi_Kliens" eszig-cmu.exe
So, the eszig-cmu.exe must stay running, but when the code executes it opens the window of the program, and I don't need it. I want to close only the window of the application, like how I mentioned and leave the .exe (the active program) running! I also apply the solution in PowerShell! I only curious about the solution!

Batch File as Service - TaskKill not killing task

If I run my batch script as normal from cmd it seems to work fine.
What I'm trying to do is setup my script as a service using nssm. That seems to work as expected except for Taskkill - this isn't killing the desired application for some reason.
Anybody have some suggestions?
This is my taskkill code in my bat file:
TASKKILL /f /t /im "application.exe"

bachfile to run taskkil for specific task in windows

i want to make a batch file to run cmd and using takkill command to stop specific task in windows.
i used this code within a file named batch.com to stop explorer:
start "runas /user:administrator" cmd /k "taskkill /im explorer.exe /f"
but when i execute the batch file a black windows appeare and then shows this error message in a dialogue box.
c:\user\jack\desktop\batch.com
The NTVDM CPU has encountered an illegal instruction.
CS:0000 IP:0077 OP:f0 37 05 0e 02 choos 'close' to terminate the application.
it has two button close and Ignore and bothe close the black window without doing anything.
when i tried the command
taskkill /im explorer.exe /f
directly in cmd it works properly.
Thanks to #rostok and #Stephan the problem is the extension. File extension should be .bat

Running an .exe after another closes using .bat file

I'm playing an old game that conflicts with the Windows Graphical Shell for Windows 7 and doesn't allow it to display properly so I simply go into Task Manager (TM) and close explorer.exe and the game displays fine but in order for me to enable explorer.exe I need to go into TM and start a new task for it to come back. I was wonder if there was a way to write a .Bat file that would kill explorer.exe launch my game and once the game closes it would simply run the task for me instead of manually needing to turn it back on.
taskkill /f /IM explorer.exe
start CNC95Launcher.exe
this is what i have so far
The start causes windows to launch your program asynchronously - that is, it will start it, then continue with the next instruction without waiting for your app to close.
Try this:
taskkill /f /IM explorer.exe
start /wait CNC95Launcher.exe
start explorer.exe
You probably don't actually need the start for explorer, because it's that kind program.
I use this (on window 7):
taskkill /F /IM Explorer.exe
*.exe
Start explorer.exe
replace * with the exe name that launches the actual game not a pre launch menu and save as .bat in the same folder directory.
It works for Star Wars Galactic Battlegrounds and AoE which can suffer weird colour issues if explorer runs.

Batch script to close all open Command Prompt windows

I have a .cmd file which I call to open multiple instances of Command Prompt via:
launcher.cmd -fs
launcher.cmd -tds
launcher.cmd -fsd
Each command open a new command prompt.
So what I want to do is create a batch file to automatically close all the opened Command Prompt instead of manually doing it.
Be carefull: you might kill more processes than you want:
taskkill /IM cmd.exe
You can add extra filters:
taskkill /IM cmd.exe /FI "WINDOWTITLE eq launcher*"
use
tasklist /FI "imagename eq cmd.exe " /V
to get a glimpse of what cmd.exe processes will be taskkill-ed
You could add the /F parameter to force the process to close but I would only use that if the process doesn't respond to a normal request.
Just a little note why accepted answer from Rene may not work. I was starting my apps from cmd file like
start "" my.exe -my -args
where my.exe was a console app and it was looking like cmd window I wanted to kill, but process name was not cmd.exe (!) and I had to use command like
taskkill /IM my.exe
So in some cases it worth to check the real process name, for example in the windows task manager.
TASKKILL /F /IM cmd.exe /T
good solution

Resources