ADMX file specify REG_EXPAND_SZ

Hello,

I am having trouble specifying a registry string type as REG_EXPAND_SZ in an ADMX template.  The ADM method was something along the lines of

PART !!CustomFolders_StartMenuPath EDITTEXT EXPANDABLETEXT REQUIRED

In the ADM format, but that obviously doesn't work in 2008 ADMX.  I attempted adding

required="true" expandable="true"

to the policy name tag with no results.

Thank you for any assistance.

omnipower321Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

merowingerCommented:
you can use the tool Reg2Adm to convert a reg file into adm adm file.
Maybe this could help you
http://yizhar.mvps.org
0
omnipower321Author Commented:
Looking for ADMX rather than ADM, but thank you.  I tried the ADMX migrator from FullArmor, but the value keys come out blank every time.  I would like to know how to write it manually rather than rely on a converter as well for future use.
0
omnipower321Author Commented:
Ok, so I have made some progress, not much but some.

<policy name="MyComputerName" class="Machine" displayName="$(string.MyComputerName)" presentation="$(presentation.MyComputerName)" explainText="$(string.MyComputerName_Help)" key="SOFTWARE\Classes\CLSID\{20D04FE0-3AEA-1069-A2D8-08002B30309D}" valueName="LocalizedString">
<parentCategory ref="2008_Profile_Management" />
<supportedOn ref="windows:SUPPORTED_WindowsVista" />
<enabledValue>
   <string>%USERNAME% on %COMPUTERNAME%</string>
</enabledValue>
<disabledValue>
   <string>Name not configured</string>
</disabledValue>
<elements>
   <text id="txtMyComputerName" valueName="LocalizedString" key="SOFTWARE\Classes\CLSID\{20D04FE0-3AEA-1069-A2D8-08002B30309D}" required="true" expandable="true" soft="true" />
</elements>
</policy>


So there is my policy, I have the apropriate language entries as well:

<presentationTable>
   <presentation id="MyComputerName">
   <textBox refId="txtMyComputerName">
   <label>Expanding key for environment variables</label>
   <defaultValue>
   </defaultValue>
   </textBox>
   </presentation>
</presentationTable>

So this creates a REG_SZ named LocalizedString with a value of %USERNAME% on %COMPUTERNAME% which is not what I need, but it also creates a REG_EXPAND_SZ with no name and no value.

So close!  Where am I messed up?
0
omnipower321Author Commented:
Solved it.

<policy name="MyComputerName" class="Machine" displayName="$(string.MyComputerName)" presentation="$(presentation.MyComputerName)" explainText="$(string.MyComputerName_Help)" key="SOFTWARE\Classes\CLSID\{20D04FE0-3AEA-1069-A2D8-08002B30309D}">
<parentCategory ref="2008_Profile_Management" />
<supportedOn ref="windows:SUPPORTED_WindowsVista" />
<elements>
<text id="txtMyComputerName" valueName="LocalizedString" key="SOFTWARE\Classes\CLSID\{20D04FE0-3AEA-1069-A2D8-08002B30309D}" expandable="true" />
</elements>
</policy>

Did not need to specify enabled and disabled values, and I was declaring the value name twice.  This works perfectly.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Active Directory

From novice to tech pro — start learning today.