WinBatch® Technical Support Forum

All Things WinBatch => WinBatch => Topic started by: keslaa on November 20, 2013, 12:36:07 PM

Title: Creating and Writing to a WMI Class
Post by: keslaa on November 20, 2013, 12:36:07 PM
Has anyone done this? I've seen the scripter for querying WMI, but nothing for what I need to do.

Eric
Title: Re: Creating and Writing to a WMI Class
Post by: Deana on November 20, 2013, 02:44:05 PM
DO you really need to create a Custom WMI class? The following code could be converted to WinBatch: http://blogs.msdn.com/b/rslaten/archive/2007/03/23/adding-custom-data-to-wmi-as-a-low-rights-user-and-having-sms-collect-that-data.aspx


Maybe share with us what you are trying to do and maybe we can offer a suggestion.
Title: Re: Creating and Writing to a WMI Class
Post by: keslaa on November 21, 2013, 10:20:42 AM
Based on something I was told, I am trying to create a Bitlocker class so as to be able to inventory for SCCM reporting. Things like DriveLabel, Size, Version of Bitlocker, % encrypted, Protection status, Lock status, etc.
Title: Re: Creating and Writing to a WMI Class
Post by: Deana on November 21, 2013, 01:20:26 PM
I believe that type of information is available in the Win32_EncryptableVolume class: http://msdn.microsoft.com/en-us/library/aa376483(v=vs.85).aspx

There is already some code in the tech database that accesses this existing WMI class: http://techsupt.winbatch.com/webcgi/webbatch.exe?techsupt/tsleft.web+WinBatch/WMI+Win32_EncryptableVolume.txt