lbriggs
Posts: 91
Score: 2 Joined: 7/10/2003 From: Hartford, CT Status: offline
|
I'm creating a mini mof file to query a particule set of registry keys pertaining to the builds in our environment. The data is currently stored in the location HKLM\SOFTWARE\MyCompany\Build\Config\NAMEOFBUILD\ The data stored under the NAMEOFBUILD subkey is a bunch of values pertaining to the software in that build. I'm not interested in that, only the name of the subkey 'NAMEOFBUILD'. I have the following MOF file written, but it doesn't appear to be doing anything:
//----------------------
// Build Information
//----------------------
#pragma namespace ("\\\\.\\root\\cimv2")
#pragma deleteclass ("win32Reg_Build",NOFAIL)
[ dynamic,
provider("RegProv"),
ClassContext("local|HKEY_LOCAL_MACHINE\\SOFTWARE\\MyCompany\\Build\\CONFIG")
]
class Win32Reg_Build
{
[key] string ScheduledJobs;
};
#pragma namespace ("\\\\.\\root\\cimv2\\sms")
#pragma deleteclass ("win32Reg_Build",NOFAIL)
[ SMS_Report (TRUE),
SMS_Group_Name ("Build Info"),
SMS_Class_ID ("MICROSOFT|BUILD_INFO|1.0") ]
class Win32Reg_Build : SMS_Class_Template
{
[SMS_Report (TRUE), key ] string ScheduledJobs;
};
//----------------------
// Build Information
//----------------------
After compiling locally with mofcomp, I inspect the class and have a null value for ScheduledJobs. Am I missing something here? Or is it not possible to query on just the subkey without asking for values under it. *looks around for SKissinger*
|