August 15, 2013 at 5:38 pm #9544
I'm working with WMI today. The class I'm working with only exists if you're using a third party software. Obviously you guys reading this will not be using that. I'm having a problem listing the available methods for the class.
First, I use the old Sapien Technologies WMI Explorer. When I click on the class, I can see 10 methods listed under the methods tab.
Second, I use the new Sapien Technologies WMI Explorer. When I click on the same class, I can only see one method listed. Compared to 10 in the first option.
Third, I use PowerShell. I do a get-wmiobject -namespace root\cimv2 -class softwarevendor | get-member. When I run that I get just the properties back and no methods. I even tried get-wmiobject -namespace root\cimv2 -class softwarevendor | get-member -membertype method. When I do that, no results returned.
I suppose I should discuss my first and second results with Sapien Technologies. However, when I used just PowerShell it really threw me off. So I thought I would check here first. If anyone has any ideas please let me know.
August 15, 2013 at 6:02 pm #9545
Are running your Powershell console in Admin context (i.e. Run As Administrator)? Outside of trying that to see if there are some permissions issues, you'll have to look at the documentation provided by the vendor or contact them for support.
August 16, 2013 at 4:52 am #9552
[quote=9545]Are running your Powershell console in Admin context (i.e. Run As Administrator)? Outside of trying that to see if there are some permissions issues, youâ€™ll have to look at the documentation provided by the vendor or contact them for support.[/quote]
Yup, running as administrator. I compared the vendors classes to some of the more well known ones, like win32_service and all that looks like what I'm used to seeing. So I think this might be related to the vendor and nothing more. Damn software vendors! 🙂
September 7, 2013 at 8:31 am #9987
The new WMI Explorer was only showing methods defined by the class itself, not inherited ones.
This has been remedied and a new build of the new WMI Explorer is available.
Just download and install again.
September 7, 2013 at 8:53 am #9988
If you have PowerShell 3.0 available try running Get-CimClass against the WMI class. Be interesting to see what is returned
You must be logged in to reply to this topic.