[WUA APIs]AutomatciUpdates

本文介绍了自动更新接口IAutomaticUpdates及IAutomaticUpdates2的功能与使用方法,包括启动、暂停和恢复更新等操作,并提供了所需的最低系统要求和技术细节。

AutomaticUpdates

文中信息皆来自MSDN,链接如下:
https://msdn.microsoft.com/en-us/library/windows/desktop/aa385821(v=vs.85).aspx

IAutomaticUpdates interface

Contains the functionality of Automatic Updates.

成员

IAutomaticUpdates接口派生自IDispatch接口,拥有该接口的所有成员。

方法
方法描述
DetectNow若更新未开始,则启动自动更新
EnableService启用所有自动更新所需的组件
Pause暂停自动更新
Resume恢复被暂停的自动更新
ShowSettingsDialog显示自动更新配置对话框
属性

IAutomaticUpdates接口所拥有的属性。

属性权限描述
ServiceEnabled只读返回所有自动更新组件是否已启动的标识(Boolean,应该是BOOL而非bool)
Settings只读获取自动更新的配置信息
注意

可使用 Microsoft.Update.AutoUpdate标识符通过AutomaticUpdates核心组件创建该接口。

使用需求
需求描述
最低客户机要求Windows XP, Windows 2000 Pro with SP3(仅适用于桌面应用)
最低服务器要求Windows Server 2003, Windows 2000 Server with SP3(仅适用于桌面应用)
头文件Wuapi.h
IDLWuapi.idl
静态库Wuguid.lib
动态库Wuapi.dll
IIDIID_IAutomaticUpdates is defined as 673425BF-C082-4C7C-BDFD-569464B8E0CE

新版本请看 IAutomaticUpdates2

IAutomaticUpdate2

IAutomaticUpdates2派生自IAutomaticUpdates接口。

方法
方法描述
Results返回一个IAuotmaticUpdatesResults接口指针
注意

与IAutomaticUpdates接口一致。

使用需求
需求描述
最低客户机要求Windows XP, Windows 2000 Pro with SP3(仅适用于桌面应用)
最低服务器要求Windows Server 2003, Windows 2000 Server with SP3(仅适用于桌面应用)
头文件Wuapi.h
IDLWuapi.idl
静态库Wuguid.lib
动态库Wuapi.dll
IIDIID_IAutomaticUpdates2 is defined as 4A2F5C31-CFD9-410E-B7FB-29A653973A0F
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值