View Full Version : Autorun to HTML

23-05-2002, 08:23 PM
Recently I made a cd that contained a photo and some other things that I wanted to send. I wanted to make the cd as easy to use as possible, and since the only thought of programing experience is with Web pages, I made a couple of pages and linked everything off it. In the way of making it easier I thought I would fiddle around and see if I could make the cd Automaticly run and load the index page when the CD was put in the drive. Creating the Autorun file was easy. However when I made the CD It wouldn't automaticly run.

Now my question. Can autorun files load HTML pages directly, if so how?
Do you have to have the Autorun file load another *.exe file that loads the HTML file?
If so is it easy to do this, if it is how do I do it. Or is there a web site where I can download a file the will load the Html page I want.



23-05-2002, 09:20 PM
Try this site

24-05-2002, 12:05 PM
This can be done thus:

Make your autorun.inf file with the following lines:

open=Wscript ShellExecute.js //B //nologo

The ICON line is the icon you wish to load into the address bar. You may rename this of course.

Then make a file named shellexecute.js containing the following script:

WshShell = WScript.CreateObject('WScript.Shell');

WshShell.Run('index.html', 1, 0);


(Note the line breaks...this script should be on 5 lines including empty lines.)

Also note that some antivirus will try to block this script but it can be allowed as it is only running your index.htm page.

Hope you have some luck,

24-05-2002, 02:52 PM
The Autorun.inf should look like this (showing the line numbers which you should leave out of course. The formatting gets lost on the message board:

3...open=Wscript shellExecute.js //B //nologo

NB: The 3rd line should be one line.
Hope this is a bit clearer. Drop me a line if you like: matt@rbsnz.com

24-05-2002, 03:18 PM
Thank you.

This site will come in very handy. I decided to write the code myself with the help of The other respondent. But thanks all the same.


24-05-2002, 03:20 PM

Thank you Very much, for this code. I'm sure it will come in very handy.