autorun on flash drive insert

  • Thread starter Thread starter shytemail
  • Start date Start date
S

shytemail

Anybody know how to have a .exe file autostart when a flash drive is
inserted? the exe file is located on the removable drive, of course.
Basically, the functionality that is built into winXP for CD's, but
i'm trying to get that to work for removable media.
 
This really isn't an option unless you have special software on the
host machine. I personally have the list of options customized when I
insert one of my usb keys by writing an autorun.inf file. What i mean
is that when i insert a certain stick (with the autorun file on it)
the list that pops up which usually says open the folder... open in
wmp... is customized. They are not so hard to make. Also, if i insert
my drive, I can right click it, and launch certain programs from the
drive. Here is an example of my autorun.inf file:

[autorun]
ICON=AUTORUN.ICO (any icon in the root)
action=Launch (this is what is shows in the pop-up menu)
open=autorun.exe start.bat (this points to your batch file, to launch
any program you want)

I basically made a few batch files, and pointed to them in the autorun
file. If I can find my old usb drive, I can show you the more
sophisticated autorun file. Good Luck
 
Just a correction, you don't need to write open=autorun.exe start.bat,
leave out the autorun.exe (that was an attempt to get something to
auto-launch using some weird program). open=start.bat will do just fine
 
Back
Top