Windows Vista Tips

Windows Vista Tips > Newsgroups > Windows Update > Trigger /resetauthorization through API

Reply
Thread Tools Display Modes

Trigger /resetauthorization through API

 
 
Björn Axéll
Guest
Posts: n/a

 
      11-11-2008
Hi,
I was wondering if someone could help me. You can trigger a
resetauthorization by executing the following command "wuauclt.exe
/resetauthorization /detectnow" but how can I do that "through" the API? For
example, below is a code that I found that will check for updates ( köra
wuauclt.exe /detectnow) but how can I trigger the "resetauthorization" part?

Dim update, i
set AutoUpdate = CreateObject("Microsoft.Update.AutoUpdate")
Autoupdate.DetectNow()
set UpdateSession = CreateObject("Microsoft.Update.Session")
set UpdateSearcher = UpdateSession.CreateUpdateSearcher()
set SearchResult= UpdateSearcher.Search("")
set Updates = SearchResult.Updates
set UpdatesToInstall = CreateObject("Microsoft.Update.UpdateColl")
For i = 0 to (Updates.Count-1)
UpdatesToInstall.Add(Updates.Item(i))
Next
set Installer = UpdateSession.CreateUpdateInstaller()
Installer.Updates = UpdatesToInstall
set InstallationResult = Installer.Install()


Thanks!

Björn Axéll


 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Suddenly got BSOD on UAC Trigger,... Kerem Gümrükcü Windows Vista Drivers 4 04-26-2009 04:16 AM
how filter can trigger ACL attributes? alexli Windows Vista Drivers 1 03-16-2009 01:31 PM
How to trigger IRP_MN_SURPRISE_REMOVAL? Sathyanarayanan Windows Vista Drivers 6 06-26-2008 08:58 PM
Does IOCTL_USB_GET_NODE_INFORMATION trigger USB bus enumeration? Alex Samoutin Windows Vista Drivers 0 06-21-2004 07:28 PM
Trigger Encoding Bob S. Windows Media Player 0 05-11-2004 01:01 PM



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59