Autorun CD Basics

Introduction to Autorun in Windows

When you insert your CD or DVD into a computer, Windows automatically starts an autorun program from your CD (if autorun function is enabled in your system)

Windows checks if a file called AUTORUN.INF is located in the root of the CD and if it finds one, then it follows the instructions located there.

This is an example AUTORUN.INF file that starts an installation program:

[autorun]
open=Install.exe

To create this file, you can edit it manually using Notepad or Wordpad program, or you can use our software 1st Autorun Express to make your CD autorun a document or display a menu

Please note, that Autorun function can be disabled on the computer. Users may be afraid of malware or viruses and turn Autorun off. Also if you press Shift during CD insertion, then Windows will skip CD Autorun.

You can not ensure that your users will have Autorun enabled or that they won't press Shift during autorun CD insertion. Therefore you should try to make it clear to the user, which autorun program they should run on your CD. For example, you can put all your documents and files into subfolders and only keep autorun index.html or autorun menu shell in the root of your autorun cd.

Viewing documents on your autorun CD

Modern versions of Windows, allows you to autorun a document using AUTORUN.INF via shellexecute command. For example:

[autorun]
shellexecute=Intro.pdf

With this AUTORUN.INF your autorun CD will display Intro.pdf when inserted into user's computer. Of course your user should have Autorun function enabled, he should not press Shift during CD insertion and it should have a software to view PDF files.

If there is no software to view PDF files on user's computer, then he won't be able to view the document, even if he will browse your autorun CD in Explorer. Therefore you need to put an installation of such a software to your autorun CD.

With 1st Autorun Express you can automatically install the software required to view your documents, if a user does not have one.

CD Autorun Menu

You may want to display several choices to your users in the autorun menu. In this case you need a software that can display a menu, because AUTORUN.INF does not allow you to specify choices.

With 1st Autorun Express you can create autorun menu for your autorun CD You only need to specify autorun documents and autorun menu will be automatically constructed for you.

Opening several documents on autorun cd

You can not open several documents with AUTORUN.INF. You can use our 1st Autorun Express to autorun multiple files at once. You can configure documents to wait each one until they are closed by user!

How to disable autorun?

In Windows Vista or Windows 7, at first go to Control Panel\Hardware and Sound\AutoPlay and disable or configure autorun settings.

A registry setting can be used to disable AutoRun. Click Start|Run then type in regedit. Select Edit|Find and type in NoDriveTypeAutoRun. This value should be found in this key: HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer.

The NoDriveTypeAutoRun value should be hexadecimal 95 if AutoRun is enabled on all CDs, or B5 if disabled for CDs. (If you want to test AutoRun on a floppy disk, set this value to 91.) You may need to change more than one instance of NoDriveTypeAutoRun in the registry. You usually need to reboot for a new value to take effect.

In Windows 95/98/Me the NoDriveTypeAutoRun value is displayed as 95 00 00 00. In Windows NT4, 2000 and XP this value is displayed as 0x00000095 or hexadecimal 95. If you modify the NoDriveTypeAutoRun value make sure it is still in the correct format.

There are two other - uncommon - ways of disabling AutoRun. The NoDriveAutoRun registry value is in the same key as NoDriveTypeAutoRun. Each bit represents each drive, so hexadecimal 01 disables AutoRun for floppy drive A, 04 disables AutoRun for drive C, 10 disables AutoRun on E. Values can be combined, so 19 disables AutoRun on E, D and A.

If either NoDriveTypeAutoRun or NoDriveAutoRun specify that AutoRun should be disabled for a drive, then it is disabled for that drive.

Finally, programmers might like to know that AutoRun can also be disabled by the program that controls the foreground window by handling the "QueryCancelAutoPlay" Windows message. Please consult the Microsoft documentation for more details.

How to enable autorun?

To enable autorun, you should ensure that autorun is not disabled in the registry, in the control panel settings etc.

In Windows Vista or Windows 7, at first go to Control Panel\Hardware and Sound\AutoPlay and enable or configure autorun settings.

Click Start|Run then type in regedit. Select Edit|Find and type in NoDriveTypeAutoRun. This value should be found in this key: HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer.

The NoDriveTypeAutoRun value should be hexadecimal 95 if AutoRun is enabled on all CDs. You may need to change more than one instance of NoDriveTypeAutoRun in the registry. You usually need to reboot for a new value to take effect.

In Windows 95/98/Me the NoDriveTypeAutoRun value is displayed as 95 00 00 00. In Windows NT4, 2000 and XP this value is displayed as 0x00000095 or hexadecimal 95. If you modify the NoDriveTypeAutoRun value make sure it is still in the correct format.

Then check the NoDriveAutoRun registry value in the same key as NoDriveTypeAutoRun. Each bit represents each drive, so hexadecimal 01 disables AutoRun for floppy drive A, 04 disables AutoRun for drive C, 10 disables AutoRun on E. Values can be combined, so 19 disables AutoRun on E, D and A. Therefore you need to check if NoDriveAutoRun is set to 0, or at least does not disable your CD drives.

Using 1st Autorun Express

1st Autorun Express let you create autorun CD to open your documents automatically or show autorun menu. 1st Autorun Express can open any kind of documents and it can automatically install the required software to view your documents.

Create autorun menu with 1st Autorun Express in a few clicks, without design or programming required!