Поделиться через


Sample Files

Applies To: Windows Server 2008

This document references two samples of ADM files, example1_SinglePolicySetting.adm and example2.adm, with their corresponding ADMX files. The Group Policy settings included in these files are fully functional. All of the policy settings displayed through the use of these sample files will configure registry settings under the registry keys, "[HKLM|HKCU]\Software\Policies\Examples". The example files can be loaded into the Group Policy Object Editor on a Windows Vista–based or Windows Server 2008–based computer. These files can serve as a starting point to experiment with authoring ADMX files. You can make changes and verify the results in the Group Policy Object Editor. As long as you do not change the registry keys, anything you do should not affect actual Windows components or applications on your machine. You can edit the files using an XML editor or a text editor such as Notepad.

The policy settings contained in these files will display in the Group Policy Object Editor under the following categories:

  • ADM file policy settings: "[computer|user] configuration\Classic Administrative Templates\Example 1 - Simplest single Group Policy setting" or "[computer|user] configuration\Classic Administrative Templates\Example 2 Policy settings"

  • ADMX file policy settings: "[computer|user] configuration\Administrative TemplatesExample 1 - Simplest single Group Policy setting""[computer|user] or configuration\Administrative Templates\Example 2 Policy settings"

These sample files can be downloaded from the Microsoft Download Center (https://go.microsoft.com/fwlink/?LinkId=86092).

To add the ADM sample files to the Group Policy Object Editor on a Windows Vista Machine

The ADM sample files can be tested using the Local Group Policy Object Editor.

  1. Copy the example.adm file to the %windir%\inf directory.

  2. To open the Group Policy Object Editor on a Windows Vista machine, click Start, click Run, then type GPEDIT.msc.

  3. Right-click either the computer or user configuration\Administrative Templates node.

  4. Click Add/Remove Templates.

  5. The browser should open to the %windir%\inf directory. Select example.adm to add this file to the Group Policy Object Editor.

To add the ADMX sample files to the Group Policy Object Editor on a Windows Vista Machine

The ADMX sample files can be tested using the Local Group Policy Object Editor. This procedure assumes the test machine is either joined to a workgroup or a domain that does not contain a central store.

  1. Before opening the Group Policy Object Editor on a Windows Vista machine:

    1. Copy the desired sample .admx file to the %windir%\PolicyDefinitions directory.

    2. Copy the corresponding sample .adml file to the %windir%\PolicyDefinitions\en-us directory.

  2. To open the local Group Policy Object Editor on a Windows Vista machine, click Start, click Run, and then type GPEDIT.msc.

  3. The Group Policy Object Editor will automatically read all ADMX files stored in the %systemroot%\PolicyDefinitions\ directory.

Note

This procedure assumes this machine is not joined to a domain with an ADMX central store.

Additional references