Autorun Anything Off of a Usb Key

by dark-shot666 in Circuits > USB

396565 Views, 61 Favorites, 0 Comments

Autorun Anything Off of a Usb Key

Autorun1.JPG
Make any usb key (pendrive/mass storage device ect.) autorun anything that you want (windows only)

Dead simple, only common sense required.

(btw this is my first instructable. tips are gladly welcome.)





AND PLEASE don't use this for bad purposes.

Get the Stuff

FF install.JPG
first off we need a couple things:
- a usb key/storage device
- microsoft notepad (comes with windows, is needed because other word processors add extra coding)
- a program/batch file/whatever you want that can launch

when you have all that, copy/install whatever you want to your usb key

Lets Make the File

Autorun Notepad1.jpg
open notepad and type:

"(Autorun)
Open=(directory of program\program name.file extention)
Action=Start (Name of program if wanted)
Label=(what you want the label to say)"

without " "s.
if you want the icon as well, add "Icon=(director of program\program name).exe"
so it would look like:

(Autorun)
Open=(directory of program\program name.file extention)
Action=Start (Name of program if wanted)
Label=(what you want the label to say)
Icon=(directory of program\program name).exe

swap out the brackets "( )" around 'autorun' with square brackets "[]"

afterwards, save it as "Autorun.inf" in the root of your usb key.

MAKE SURE THE FILE EXTENTION IS " .inf "

example of what it would look like to launch firefox portable that was just installed:

(Autorun)
Open=FirefoxPortable\FirefoxPortable.exe
Action=Start Firefox Portable
Label=MY USB
Icon=FirefoxPortable\FirefoxPortable.exe

the image below shows the directory of Firefox Portable on my usb key

Hide It

Autorun Properties.jpg
Hiding the file will not make it visible (duh) so that it cant be deleted accidentally.


now go to the file, and right click it, and click "properties"

in the attributes section check the box beside "hidden" and click apply.

Try It

Autorun1.JPG
My pc - 1.jpg
My pc - 2.jpg
remove the usb key, and plug it back in. If all was done right it should Autorun. If not just double click the usb key icon in my computer and it should launch! There you have it.

NOTE: If you do have other things on your usb key that you want to access, right click the usb icon in my computer and click "open"