I am trying to write a PowerShell Script, which queries on a local Client the SCCM WMI Tree root\ccm\ClientSDK
we want to have the info was PostInstallaction an Application is using (Yes we know several other ways to find it out but we need it on the Client and it has to run when no connection to the Siteserver is given.
we know that the information is in CCM_AppDeploymenType -> PostInstallAction. But this is as an Object in CCM_Application in the Property AppDTs as an Array/Object all of it has the Superclass CCM_SoftwareBase
WMI CIM Studio is able to open and show us what I want, but it gives me no Queries to use. WMI Explorer is not able to give me anything.
so in short how do I Query CCM_Application -> AppDTs -> Array of Object CCM_AppDeploymentType PostInstallAction.
Thank in advance
So we found a solution or better said one of our contacts got through..
$ID = SCOPEID
$CCMApp = [WMIClass]'root\ccm\clientsdk:ccm_application'
$CCMAppObj = $CCMApp.GetInstances() | where { $_.id -eq $ID }
$CCMAppObj.Get()
$result = $CCMAppObj.AppDTs[0].PostInstallAction
regards