locked
Patch Update - Collection Based on "Enforcement State Unknown" RRS feed

  • Question

  • I am having some difficulty in creating a collection based upon the patch update state "Enforcement State Unknown"

    Can anyone offer any assistance?

    Friday, February 22, 2013 4:37 PM

Answers

  • Run this script on clients and check. 

    Create a package with the script and configure it to run daily. It'll force a state update on the client and upload the information to the MP.

    Option Explicit
    On Error Resume Next

    Call RefreshServerComplianceState

    ' WScript.Echo "Finished"

    Sub RefreshServerComplianceState()

        ' Initialize the UpdatesStore variable.
        dim newCCMUpdatesStore
       
        ' Create the COM object.
        set newCCMUpdatesStore = CreateObject ("Microsoft.CCM.UpdatesStore")

        ' Refresh the server compliance state by running the RefreshServerComplianceState method.
        newCCMUpdatesStore.RefreshServerComplianceState
       
        ' Output success message.
    '    wscript.echo "Ran RefreshServerComplianceState."

    End Sub

    • Marked as answer by Yog Li Monday, March 4, 2013 8:38 AM
    Saturday, March 2, 2013 4:46 PM

All replies

  • Yeh, not really a big help.
    Tuesday, February 26, 2013 6:49 PM
  • Run this script on clients and check. 

    Create a package with the script and configure it to run daily. It'll force a state update on the client and upload the information to the MP.

    Option Explicit
    On Error Resume Next

    Call RefreshServerComplianceState

    ' WScript.Echo "Finished"

    Sub RefreshServerComplianceState()

        ' Initialize the UpdatesStore variable.
        dim newCCMUpdatesStore
       
        ' Create the COM object.
        set newCCMUpdatesStore = CreateObject ("Microsoft.CCM.UpdatesStore")

        ' Refresh the server compliance state by running the RefreshServerComplianceState method.
        newCCMUpdatesStore.RefreshServerComplianceState
       
        ' Output success message.
    '    wscript.echo "Ran RefreshServerComplianceState."

    End Sub

    • Marked as answer by Yog Li Monday, March 4, 2013 8:38 AM
    Saturday, March 2, 2013 4:46 PM
  • Hi,

    As this thread has been quiet for a while, we assume that the issue has been resolved. At this time, we will mark it as "Answered" as the previous steps should be helpful for many similar scenarios.

    In addition, we’d love to hear your feedback about the solution. By sharing your experience you can help other community members facing similar problems.

    Thanks,


    Yog Li
    TechNet Community Support

    Monday, March 4, 2013 8:39 AM