Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: Run Multiple Explorer.Exe At A Time

02 Sep 2015   #1
Adonix44

Windows 7 Ultimate x64
 
 
Run Multiple Explorer.Exe At A Time

Hello guys,..

Actually i am using below bat command to terminate all explorer.exe in task manager and then after termination restarting it !
But have little problem,..after termination of explorer.exe from all users it at last opens only 1 explorer.exe for the guy who runned that bat file

Quote:
@echo off
taskkill /f /IM explorer.exe
start explorer.exe >nul
exit
So any way to upgrade my above little code so that it can open all other users explorer.exe which are terminated in first step.


My System SpecsSystem Spec
.
02 Sep 2015   #2
LMiller7

Windows 7 Pro 64 bit
 
 

That is actually a big problem, one for which I see no practical solution. Windows allows you to run a program as another user, the problem being you would need to know the login credentials of that user. The ability to do otherwise would be a security risk. On general principles you should not know another users password and there is no way to determine this.

On general principles you really shouldn't be terminating processes belonging to another user. This could only be justified under exceptional circumstances. Actually why are you terminating any instances of explorer.exe?
My System SpecsSystem Spec
02 Sep 2015   #3
Adonix44

Windows 7 Ultimate x64
 
 

I am terminating explorer.exe and reopening because to refresh all users accounts.
Like suppose i edit some registry settings so it needs pc restart to see the effect. So by killing explorer.exe and reopening that again results in refreshing the effects or registery edits!
So that's why asking how to kill and reopen explorer.exe for all users in some single click :)
My System SpecsSystem Spec
.

03 Sep 2015   #4
Pyprohly

Windows 10, Windows 8.1 Pro, Windows 7 Professional, OS X El Capitan
 
 

Adonix, you do realise that your batch file will kill every user's Explorer process if and only if the script is run as administrator, and if the script is not running elevated, it will only kill the current user's Explorer process.

Also worth noting, if you start an instance of Explorer through an elevated process, the resulting Explorer process will be elevated, and thus will all processes that this new Explorer spawns. It would be a bit like using the builtin Administrator account.

Quote   Quote: Originally Posted by Adonix44 View Post
So any way to upgrade my above little code so that it can open all other users explorer.exe which are terminated in first step.
I too do not see a practical solution here. It's very tricky to start an application on another user's desktop.
My System SpecsSystem Spec
03 Sep 2015   #5
LMiller7

Windows 7 Pro 64 bit
 
 

It is possible to run a program in another users session. Processor Hacker can do that. But that process will be running under your account, as will all child processes it may start. That is not acceptable for the explorer.exe process. And then there are the issues pointed out by Pyprohly. What you want might conceivably be done but it would require some very sophisticated programming and break more than a few rules in the process. This is far beyond what could be done with a batch file.

Messing with another users session is not something you should normally be doing. You need a really compelling reason to do this. Your proposed solution (if it could be done at all) would create all kinds of problems). This is one of those things that seem simple on the surface, something that could be done with a simple batch file. But when you have to confront the harsh facts of reality they become anything but simple. When a proposed solution is that complex that is a good indication that your entire approach is wrong.
My System SpecsSystem Spec
03 Sep 2015   #6
Adonix44

Windows 7 Ultimate x64
 
 

Quote:
@echo off
taskkill /f /IM explorer.exe
start explorer.exe >nul
exit
last thing if we use this above trick to kill explorer.exe and then re open it, then it kills explorer.exe for all users,..so is there any code to kill only explorer.exe of that person who uses this code ? and not others explorer.exe can be closed ??
My System SpecsSystem Spec
03 Sep 2015   #7
Pyprohly

Windows 10, Windows 8.1 Pro, Windows 7 Professional, OS X El Capitan
 
 

Quote   Quote: Originally Posted by LMiller7 View Post
It is possible to run a program in another users session. Processor Hacker can do that.
How?


Also, Adonix, your batch file...
Code:
@echo off
taskkill /f /IM explorer.exe
start explorer.exe
exit
can be simplified to,
Code:
@tskill explorer
where the command 'tskill explorer' is the common way of refreshing the Explorer process, and the '@' in front of the line supresses the prompt text for that line (in contrast to '@echo off' which supresses the prompt text for the entire script), and the 'exit' command is not really needed.



Edit: (the above post was submitted in the same minute as this post)
Quote   Quote: Originally Posted by Adonix44 View Post
if we use this above trick to kill explorer.exe and then re open it, then it kills explorer.exe for all users,..so is there any code to kill only explorer.exe of that person who uses this code ?
Yep. Refreshing Explorer for the current user is precisely what the simplified version of your batch snippet I've just posted does.

The command,
Code:
taskkill /f /im explorer.exe
does not kill all instances of Explorer.exe for all user's on its own. Only if you run the command as administrator it will.
My System SpecsSystem Spec
03 Sep 2015   #8
LMiller7

Windows 7 Pro 64 bit
 
 

Processor Hacker has facilities to run a program under another session or user. These are accessible from the "Run As" command under the "Hacker" menu. Of course to run as another user you need to know the users password. You can also run a program in a different users session with your own account. I know this works because I have done it. As for the details of how it is done, for that you would need to ask the developer.
My System SpecsSystem Spec
Reply

 Run Multiple Explorer.Exe At A Time




Thread Tools




Similar help and support threads
Thread Forum
multiple BSODs at random time
Hello everybody, since 2 weeks my notebook is having some Bsod. In order BAD_POOL_HEADER DRIVER_IRQL_NOT_LESS_OR_EQUAL MEMORY_MANAGEMENT DRIVER_VERIFIER_IOMANAGER_VIOLATION DRIVER_VERIFIER_DETECTED_VIOLATION
BSOD Help and Support
Multiple users at the same time
Hello, I am not sure if this is the correct subforum to post in, if not sorry. I got a simple yet not sure if possible idea. I got the idea when friends come over and I have no second / third / possibly fourth machine for them but since my machine is such an overkill I was thinking about...
General Discussion
Multiple BSOD in a month's time...HELP Please
hi there, I installed Win 7 Ultimate 64 bit last February and it worked fine, but just this month I having an awful lot of BSOD, attached herewith are the minidumps, hope somebody could help me out whats wrong? Thanks in advance....
BSOD Help and Support
how to use multiple connection at a time ???
hi all... i've got a broadband connection which is a lan wired connection and i also have an internet connection which i can use it in my laptop.. but the problem is that i can't use them both at once... so is there a way to do it ??
Network & Sharing
multiple time zones
Hi guys, I am wondering if there is a method or tool to view multiple time-zones in windows 7, I can do it on XP if I add the timezones application for windows XP. but I think maybe in windows 7 you might be able to do it within the OS like gadjet or something. if someone has done it or have an...
General Discussion


Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 03:46.
Twitter Facebook Google+ Seven Forums iOS App Seven Forums Android App