About Program Manager InitializationAbout Program Manager Initialization*
*Contents  *Index  *Topic Contents
*Previous Topic: Shell Dynamic Data Exchange Interface
*Next Topic: Command-String Interface

About Program Manager Initialization


Program Manager starts automatically when the user starts Windows and runs as long as Windows is in use. When it starts, Program Manager displays one or more windows within its main window. Each window contains icons that correspond to logically related Windows-based applications. For example, the Accessories window contains icons for Windows Write, Paintbrush, Notepad, and other accessory applications.

Program Manager stores initialization and configuration information in the registry. This information is stored under the Settings, Groups, and Restrictions keys in the following section of the registry:

HKEY_CURRENT_USER\Software\Microsoft\WindowsNT\
        CurrentVersion\Program Manager

Additional information is stored in the Program Groups key in the following section of the registry:

HKEY_LOCAL_MACHINE\SOFTWARE

Settings Key

The Settings key contains information that Program Manager uses to configure its environment. The following entries appear in the Settings key.
Entry Description
MinOnRun Specifies whether to minimize Program Manager when an application is started.
AutoArrange Specifies whether Program Manager should automatically arrange icons within groups.
SaveSettings Specifies whether to save the position of the Program Manager window when Program Manager terminates.
Display.drv Specifies the file name of the display driver in use when Program Manager last terminated. When Program Manager starts, it compares this value to the file name of the display driver currently in use. If the names are different, Program Manager re-extracts the application icons.
Window Specifies the location and dimensions of the Program Manager window.
Order Specifies the order that the groups listed in the Groups key appear in the Program Manager window.
Startup Specifies the name of the startup group. Program Manager automatically starts the applications in this group whenever it starts.

Groups Key

The windows that appear in the Program Manager window correspond to group files. From the user's perspective, a group file is a collection of icons that represent logically related applications, but from the programmer's perspective, a group file is actually a collection of data. This data includes the color information for the icons (AND and XOR masks), an offset to the resource header of each icon, the ideal resolution for displaying each icon, the name of the executable (.exe) file that contains the application, and so on.

There are two types of groups: common and personal. A common group is shared among multiple users through network connections; a personal group is not shared. Program Manager stores information about personal groups under the Groups key. It stores information about common groups under the HKEY_LOCAL_MACHINE\SOFTWARE key.

The Groups key of the registry identifies the names of the group files that Program Manager displays as unique windows or icons. The groups must be numbered, but they don't need to be listed in any particular order. Program Manager never changes the number of an existing group.

Restrictions Key

The Restrictions key controls whether certain features of Program Manager are enabled or disabled. The following entries can appear in the Restrictions key.
Entry Description
NoRun Specifies whether to disable the Run command on the File menu. If this entry is set to 1, the Run command is disabled. If this entry is set to 0, the Run command is enabled. The default is 0 if no value is specified.
NoClose Specifies whether to prevent the user from closing Program Manager through the File menu, the System menu, the ALT+F4 key combination, or the Task List. If this entry is set to 1, closing is prevented. If this entry is set to 0, closing is allowed. If no value is specified, the default is 0.
EditLevel Controls the extent to which the user can modify read/write groups. (Shared read-only groups cannot be modified.) This entry can be set to one of the following values.
Value Action
0 Allows any modifications to the group. This is the default value.
1 Prevents the user from creating, deleting, or renaming groups.
2 Prevents the user from creating, deleting, or renaming groups and from creating or deleting items in a group.
3 Prevents the user from creating, deleting, or renaming groups; from creating or deleting items in a group; and from changing command lines for items in a group.
4 Prevents the user from changing any property of an item in a group; from creating, deleting, or renaming groups; from creating or deleting items in a group; and from changing command lines for items in a group.
NoFileMenu Specifies whether to disable the File menu and all of its commands. If this entry is set to 1, the File menu is disabled. If this entry is set to 0, the menu is enabled. If no value is specified, the default setting is 0.
NoSaveSettings Specifies whether to disable the Save Settings on Exit command on the Options menu. If this entry is set to 1, the Save Settings on Exit command is disabled. If this entry is set to 0, the command is enabled. If no value is specified, the default setting is 0.

Setting the value of NoRun to 1 and the value of EditLevel to 3 prevents a user from using Program Manager to run any applications not already in a program group.


Up Top of Page
© 1997 Microsoft Corporation. All rights reserved. Terms of Use.