Forgive my ignorance...I was asked if there is any sort of command line that could be placed at the end of an install to update SCCM that the application had been installed. Of course this is a manager looking for real time reporting lol But I poked around and didnt come across anything and thought I would ask and see if anyone had thoughts??

Answer Summary:
Run the below script at the end of the install to update software inventory. You can also run a report to see what devices have completed the given advertisement.
0 Comments   [ + ] Show Comments


Please log in to comment

Community Chosen Answer


You can trigger the below VBScript to force software inventory:


sInventoryActionID = "{00000000-0000-0000-0000-000000000002}"
Set oLocator = CreateObject("WbemScripting.SWbemLocator")
Set oServices = oLocator.ConnectServer( , "root\ccm\invagt")
oServices.Delete "InventoryActionStatus.InventoryActionID=""" & sInventoryActionID & """"
wscript.sleep 3000
Set cpApplet = CreateObject("CPAPPLET.CPAppletMgr")
Set actions = cpApplet.GetClientActions
For Each action In actions
If Instr(action.Name,"Software Inventory") > 0 Then
End if

Answered 05/16/2012 by: adilrathore
Fourth Degree Black Belt

  • This chappie is on the right path imho. There is no command line, and it's not how Config Manager is meant to work. However you could force the machine to run an inventory... unless it is esential to have the status message sent back to the MP immediately, I'd leave it and let the client handle things as it normally would.
  • Wouldn't it be better to run a Hardware Inventory, seeing as Add/Remove Programs inventory data is stored in HWINV?

    I would just run the the "Status of a specific advertisement" report and give management a link to that report.
Please log in to comment



You will not get real time data with SCCM the way it is designed to work, i would:

1. run reports to see what devices have completed the advertisement 


2. add adilrathore's script to the end of the install to update software inventory.

Answered 05/17/2012 by: GAKIS
Second Degree Green Belt

Please log in to comment
Answer this question or Comment on this question for clarity