Quantcast
Channel: Microsoft Community - Super Fresh
Viewing all articles
Browse latest Browse all 1237235

Windows Update List Query

$
0
0

Hello.

I'm developing WindowsUpdate Custom Control Function of Windows10.(and the lower versions already completed.

I'm using IUpdateSearcher2, and the code is below.

   sQuery = _T("isinstalled=1");

   pUpdateSearcher->Search(CComBSTR(sQuery), &pResult);

I thought, this function is usable in the Windows Power Shell, so, I found the script, and execute the query in Windows 7, and it worked!

But, I run the query in Windows 10, but it didn't worked.

So, I'm just qurious. Is there any method to query Windows Core Update List using PowerShell or any other methods in Windows 10?

            $Session New-Object -ComObject Microsoft.Update.Session           

            $Searcher $Session.CreateUpdateSearcher()           
            $Criteria "IsInstalled=1 or IsInstalled=0"           
            $SearchResult $Searcher.Search($Criteria)          

            $SearchResult.Updates

It works in Windows 7(return update list), but dosen't work in Windows 10.(return 0 list)

(When I firstly installed Windows10, it partitially worked. some lists returned, but all didn't. I need Windows Update Full list.)

(I don't want Get History Query, I also need list to update[receive])


Viewing all articles
Browse latest Browse all 1237235

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>