Wednesday, March 11, 2009

Create Autorun.inf File :

Autorun.inf file is commonly used in Pendrive and CD/DVD-ROM to customize them according to our requirement. This tool is very flexiable and helps us to automate certain tasks.This file is simple text file which can be edited with any basic text editors.

As in any other program or file Autorun file also has the header which starts with [Autorun] below this we can add different options as required the most commonly used options are...

1) Change Icon :
To change icon its piety simple eg:Icon=Autorun\Ryu.ico now what it does is sets Ryu.ico which is inside the folder Autorun as the drive icon, We can also specify icons which are as resource in .exe file for eg:Icon=Autorun\Ryu.exe,0 or icon=\Autorun\fileabcd.dll,5

2) Autoplay Option :
To open an program we use OPEN option eg:Open=RunRyu.exe now what it does is that opens up the Ryurun.exe file automatically or when double clicked, we also use action=Runs the program now by doing this we have added the text to XP's autoplay dialog box.(May not work for pendrive so use shell option shown below.)
Now for the advanced customization have you ever thought how cool it would be if we can add some thing to Context Menu of our drive so that its easy to run an task or program just by clicking them from outside the drive without even entering your drive.

3) Context Menu :
For that we will use shell option Eg:shell\Run=Run program 1 this will display Run program 1 on context menu what we have done is called shell and assigned a name(Run)and gave an display name(Run program 1), but windows will not know what to do when pressed so we will use command attribute Eg:shell\Run\command=P1.exe this will run the P1.exe program when clicked,note that Run which is the name we created remains unchanged.

4) Automation :
The shell option is very powerful we can use it to run any file as required eg:shellexecute=http://www.Ryusystems.com will open the site in default browser. another eg: shell\readme = Read Me
shell\readme\command = notepad readme.txt.

Now i think its time for you to try them on your own, and to mention we have covered only basic concepts but you can use them to perform extreme tasks.

No comments:

 
Website Design Sydney
Website Design Sydney