Article ID: 296717 - View products that this article applies to.
This article was previously published under Q296717
When you use an Active Server Pages (ASP) page to stream back the binary contents of an Office file, such as a Microsoft Word document or a Microsoft Excel workbook, you may be prompted to specify whether to open the file directly or save the file to a disk. This is expected behavior on a newly installed client computer. If you clear Always ask before opening this type of file in the dialog box, you are usually not prompted again. However, on some computers you always receive the prompt, even if you have cleared this option.
Internet Explorer checks both the settings for the Multipurpose Internet Mail Extensions (MIME) type and the file extension. When you are prompted the first time, it is because the EditFlags registry setting has not been set for that file type previously. If you clear the Always ask option, the EditFlags entry is made for that file type. However, because the URL points to an ASP file, Internet Explorer also looks at the settings for the ASP file type if one is registered on the system. If the ASP file type is registered, but has been configured to prompt, you receive the prompt regardless of the settings for the MIME type.
There are two ways to resolve the problem:
Internet Explorer resolves whether to prompt for a downloaded file based on the file extension. If an ASP page is accessed and the ASP extension is registered on your computer, you will probably be prompted to confirm whether you want to open it if the content is not HTML, XML, GIF or JPEG (that is to say, if the MIME content type headers indicate that the page is of a type that Internet Explorer does not natively support). You may also receive a prompt depending on the settings for the file type that is specified by the MIME content type. To avoid any prompts, clients with a registered ASP extension need to configure both the ASP file type and the file type that is specified by the MIME content so that they do not prompt. See the steps above for an example of how to change this setting.
Clearing Confirm open after download adds a special binary value to the registry key that describes that file type. The DWORD value is called "EditFlags" and a setting of "0x00010000" turns off the prompt for that file type. For example, the following REG file script turns off the dialog box for Word 97, Word 2000, and Word 2002 documents:
Because different products may register the ASP extension differently, the above REG script cannot fix the issue that is discussed in this article because the exact mapping of the .asp extension to its file type registry key (typically but not exclusively aspfile) cannot be known for all cases. Developers who want to programmatically set this client key must find the correct registry key from the extension by using the Windows registry application programming interfaces (APIs).
Article ID: 296717 - Last Review: May 12, 2007 - Revision: 6.1