In Windows, how do I associate an application with a file type?
To ensure that a particular application (e.g., Notepad) handles a
given file type (e.g., a .txt file):
Note: The File Extension Source lists most file extensions and their associated programs.
- From the desktop or
Startmenu, selectMy ComputerorComputer. This will open a folder that shows all of the drives located on your system.Note: The Windows XP default desktop view and
Startmenu are different from the Windows Classic View (e.g., in Windows 2000). Therefore, navigating to certain items can be different. In the interest of broad applicability, most Knowledge Base instructions assume you are using Classic View. For details about switching views, see In Windows XP, how do I switch to the Windows Classic View, Classic theme, or Classic Control Panel?Note: The Windows Vista
Startmenu and Control Panel are different from the Windows Classic View (e.g., in Windows 2000). Therefore, navigating to certain items can be different. In the interest of broad applicability, most Knowledge Base documents assume you are using the Classic View. For information about switching your Windows Vista default view to Classic View, see In Windows Vista, how do I switch to the Windows Classic Start menu or Classic Control Panel? - From the
Toolsmenu, selectFolder Options....Note: In Windows Vista, if the menu bar is not visible at the top, press the
Altkey to display the menu. - In the window that opens, click the
File Typestab, and then clickNew.
- Fill in the "File Extension" box with the file extension (the
letters after the period in the filename) that you want to associate.
- Click
Advanced. This will open a field for "Associated File Type". You can select the type of file that this extension is associated with from the drop-down list, or allow Windows to specify it. Once this is completed, clickOK. If the files with that extension already have an association, you will get an error that says something like:
If this happens, click"Extension '.txt' is already associated with the File Type Text Document. Do you want to un-associate .txt with Text Document and create a new File Type for it?"
Noand see the section below on editing a file association.
- Click
Advanced, and then clickNew.
- In the
New Actiondialog box, in the "Action" field, type: open - In the next field, type the full path to the application that
should be used to open the file. If you don't know the full path, you
can click
Browse...to find it. After you finish, clickOK.
- If all the information is correct, click
Close. You will see the newly created icon in the subwindow. ClickCloseagain.
Any file with the extension you just specified will open in the associated application when you double-click the file.
Editing a file association
To edit a file association, follow the first three steps above to
get to the Folder Options or Options window,
and then:
- Search the list under "Registered file types" for the program that
is currently registered to open files with the extension you'd like to
edit. This can be the most difficult step because the actual listing
for the file type under "Registered file types:" may not match the
error you received in step 5 above. You may have to highlight each item
one by one and look at the extension listed under "File type details"
to find the file type associated with the particular extension you
wish to edit.
- When you find the file type, highlight it and click
Delete.
- Return to step 5 above to continue creating a new file association.
Example of creating a file association
Here is a specific example of how you would associate all files that
have the extension .txt with the Notepad application that
comes with Windows:
- Double-click
My Computer.
- From the
Toolsmenu, selectFolder Options....
- Click the
File Typestab, and then clickNew.
- In the "File Extension" field, enter: .txt
- Click
OK, then clickAdvanced, and then clickNew....
- In the "Action" field, type: open
- In the "Application used to perform action:" field, type: c:\windows\notepad.exe
- Click
OK, and then clickClose.
From now on, all files with the extension .txt will be
opened by the Notepad application.
Last modified on May 13, 2009.







