Creating VSDIR Files

See Also

You can optionally create a .vsdir file for your wizard, or modify an existing file to contain information about the wizard. A .vsdir file is a text file that is used to provide information to the Add Item dialog and the New Project dialog boxes. The .vsdir provides information about the items these dialog boxes display, such as the sort order and the icon to display for each item.

You can have multiple .vsdir files in a single directory; however, one .vsdir file is generally used to contain information for multiple wizards, folders, or templates. An example of a typical .vsdir file is shown below:

Form.java|{AECC23E0-8AA3-11d0-B606-00A0C922E851}|#36201|10|#36202|{AECC23E0-8AA3-11d0-B606-00A0C922E851}|#253|0|Form

Control.java|{AECC23E0-8AA3-11d0-B606-00A0C922E851}|#36203|20|#36204|{AECC23E0-8AA3-11d0-B606-00A0C922E851}|#258|0|Control

DATAFORM.VSZ|{AECC23E0-8AA3-11d0-B606-00A0C922E851}|#36220|40|#36221|{AECC23E0-8AA3-11d0-B606-00A0C922E851}|#262|0|DataForm

Form|{AECC23E0-8AA3-11d0-B606-00A0C922E851}|#36056|10
Class|{AECC23E0-8AA3-11d0-B606-00A0C922E851}|#36054|20

.vsdir files contain a single record per file or folder template, with fields separated by a pipe ( | ) character. Any non-required field for which there is no meaningful data should contain a zero ( 0 ) as a placeholder. The following fields can be specified for a given record:

Field Meaning
RelPathName Name of the .vsz file for the wizard.
{clsidPackage} Optional GUID representing a product (for example, Visual J++) that has a DLL containing localized resources.
LocalizedName Optional name of the wizard as it will appear in the Add Item dialog — can be a string or a resource identifier of the form: "#ResID."
SortPriority An integer representing the relative priority of the wizard, with 1 being highest. Determines the sort order of items.
Description Localizable description of the template or wizard as it will appear in the Add Item dialog box — can be a string or a resource identifier of the form: "#ResID."
DLLPath or {clsidPackage} Used to load an icon for the wizard from a .dll or .exe file. Specify either the full path to the .dll or .exe, or a GUID of a product that has a .dll file containing localized resources.
IconResourceId Optional resource identifier within the .dll file that determines the icon to display. If no icon is defined, the shell substitutes the default icon for a file with the same extension as the item.
Flags A group of flags that disable or enable the Name and Location fields on the Add Item dialog box. The flags can have the following values:

Space (" "): enable file name

8192:   disable file name

SuggestedBaseName The default name for the wizard — either a string or a resource identifier of the form: "#ResID." If necessary, the shell appends the base value with an integer to make the name unique. For example, the shell might change MyFile.asp to MyFile1.asp.

This default name is shown in the name field in the dialog.