Do you know we can set up our thumb drives so that it automatically runs a program when we plug it into a Win XP SP2 pc? It doesn't work if no SP2 installed. we can also apply custom drive icon and give the drive any name we like, not just the standard 11-character drive label normally permitted by windows.
To do this, create a text file (can use the Notepad program) named Autorun.inf in the drive's root directory with contents like this:
[autorun]
open=PortableFirefox.exe action=Start PortableFirefox
icon=PortableFirefox.exe label=Portable Internet
The open= line specify the action that the Autoplay dialog will offer to perform.
The action= line specify the text that the dialogue will display to describe that action.
The files we specify can be anywhere in the thumb drive, but if they're not in the root directory, we must include the full path and omit the drive letter cause we don't know what letter the drive will be assigned to when plugged into the pc.
The icon= and label= lines indicate the icon and name of the drive as displayed in Windows Explorer.
The icon can be a program file's built-in icons or any other icons resource such as a DLL or ICO file. The first icon in the file is used as default. To use other icon, simply type a comma and a number starting with 0 following the filename. 0 applies to the first icon (the default icon). For example:
open=PortableFirefox.exe,2
So, the number 2 applies to the third icon in the PortableFirefox.exe file.
To do this, create a text file (can use the Notepad program) named Autorun.inf in the drive's root directory with contents like this:
[autorun]
open=PortableFirefox.exe action=Start PortableFirefox
icon=PortableFirefox.exe label=Portable Internet
The open= line specify the action that the Autoplay dialog will offer to perform.
The action= line specify the text that the dialogue will display to describe that action.
The files we specify can be anywhere in the thumb drive, but if they're not in the root directory, we must include the full path and omit the drive letter cause we don't know what letter the drive will be assigned to when plugged into the pc.
The icon= and label= lines indicate the icon and name of the drive as displayed in Windows Explorer.
The icon can be a program file's built-in icons or any other icons resource such as a DLL or ICO file. The first icon in the file is used as default. To use other icon, simply type a comma and a number starting with 0 following the filename. 0 applies to the first icon (the default icon). For example:
open=PortableFirefox.exe,2
So, the number 2 applies to the third icon in the PortableFirefox.exe file.
