|
Answer» Sometimes it happens that the icon for safe removal of hardware disappears from the Windows task bar.
The way to RESTORE it is to run the following command:
"RunDll32.exe shell32.dll,Control_RunDLL hotplug.dll"
Now I would like to WRITE a BAT file that does this, so I could simply click on an icon to restore the safe removal function. Would anybody like to help me with this?
If I recall, just put your code (RunDll32.exe shell32.dll,Control_RunDLL hotplug.dll) into a batch file (a text file and save as file.bat), and then just put that batch file onto your desktop.
Voila.Oh well... was it that simple?
It does seem to work! THANKS!Just an addition: With this command in the batch file, the command prompt window stays open behind the Safe removal window until that is closed. Is there a way to write the batch file so that the command prompt window closes automatically?Well, I'm not too sure about this, but try adding exit at the end of the file.Well, I had already added the EXIT command - but that does not help...QUOTE from: Hans_N on SEPTEMBER 07, 2007, 11:03:31 AM Well, I had already added the EXIT command - but that does not help...
You need something like this. When you open something in that way the batch file will wait until it is finished before continuing, like 'calling' it. You need to 'start' it.
This works for me.
Quote@echo off start RunDll32.exe shell32.dll,Control_RunDLL hotplug.dll exit Yes - that did the trick - thanks!
(And BTW in other batch files I have created, I have the START command, so I should have thought of that.)
|