How to Define File Type Attributes

Assigning file type attributes to an associated ProgID enables you to control some aspects of the file type's behavior. Prior to Windows Vista, these attributes could enable you to limit the extent to which the user could use the Folder Options property tab to modify various aspects of the file type, such as its icon or verbs.

File type attributes are binary flags specified as REG_DWORD or REG_BINARY values in the file type's associated ProgID subkey.

To assign attributes for a file type, follow these steps.


Step 1:

Add an EditFlags entry to the file type's associated ProgID subkey.

Step 2:

Set the entry to the appropriate attribute value.

The following example shows the FTA_NoRemove (0x00000010) and FTA_NoNewVerb (0x00000020) attributes set for the .myp file type.

      (Default) = ApplicationVendor.MyProgram
      (Default) = MyProgram Application
      EditFlags = 0x00000030


The flags can be combined with a logical OR to form the single attribute value.

For a list of possible file type attributes and their hexadecimal values, and more details on programmatically retrieving and setting these values, see FILETYPEATTRIBUTEFLAGS.