diff --git a/PInvoke/WUApi/WUApi.cs b/PInvoke/WUApi/WUApi.cs
index 2e97e4d9..4979bbc0 100644
--- a/PInvoke/WUApi/WUApi.cs
+++ b/PInvoke/WUApi/WUApi.cs
@@ -1,7 +1,6 @@
global using System.Collections;
global using System.Reflection;
global using System.Runtime.CompilerServices;
-using System.Net;
namespace Vanara.PInvoke;
@@ -899,7 +898,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iautomaticupdates
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IAutomaticUpdates")]
- [ComImport, Guid("673425BF-C082-4C7C-BDFD-569464B8E0CE"), CoClass(typeof(AutomaticUpdates))]
+ [ComImport, Guid("673425BF-C082-4C7C-BDFD-569464B8E0CE"), CoClass(typeof(AutomaticUpdatesClass))]
public interface IAutomaticUpdates
{
///
@@ -992,7 +991,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iautomaticupdates2
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IAutomaticUpdates2")]
- [ComImport, Guid("4A2F5C31-CFD9-410E-B7FB-29A653973A0F"), CoClass(typeof(AutomaticUpdates))]
+ [ComImport, Guid("4A2F5C31-CFD9-410E-B7FB-29A653973A0F"), CoClass(typeof(AutomaticUpdatesClass))]
public interface IAutomaticUpdates2 : IAutomaticUpdates
{
///
@@ -1104,7 +1103,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-uamg/edb37e74-f222-4983-b1fc-4d9694386619
[DispId(1610743809)]
- object LastSearchSuccessDate
+ object? LastSearchSuccessDate
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
[return: MarshalAs(UnmanagedType.Struct)]
@@ -1121,7 +1120,7 @@ public static partial class WUApi
/// this property.
///
[DispId(1610743810)]
- object LastInstallationSuccessDate
+ object? LastInstallationSuccessDate
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
[return: MarshalAs(UnmanagedType.Struct)]
@@ -1663,7 +1662,7 @@ public static partial class WUApi
// CheckPermission( [in] AutomaticUpdatesUserType userType, [in] AutomaticUpdatesPermissionType permissionType, VARIANT_BOOL
// *userHasPermission );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610809346)]
- bool CheckPermission([In][ComAliasName("WUApiLib.AutomaticUpdatesUserType")] AutomaticUpdatesUserType userType, [In][ComAliasName("WUApiLib.AutomaticUpdatesPermissionType")] AutomaticUpdatesPermissionType permissionType);
+ bool CheckPermission([In, ComAliasName("WUApiLib.AutomaticUpdatesUserType")] AutomaticUpdatesUserType userType, [In, ComAliasName("WUApiLib.AutomaticUpdatesPermissionType")] AutomaticUpdatesPermissionType permissionType);
}
/// Contains the settings that are available in Automatic Updates.
@@ -1946,7 +1945,7 @@ public static partial class WUApi
// CheckPermission( [in] AutomaticUpdatesUserType userType, [in] AutomaticUpdatesPermissionType permissionType, VARIANT_BOOL
// *userHasPermission );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610809346)]
- new bool CheckPermission([In][ComAliasName("WUApiLib.AutomaticUpdatesUserType")] AutomaticUpdatesUserType userType, [In][ComAliasName("WUApiLib.AutomaticUpdatesPermissionType")] AutomaticUpdatesPermissionType permissionType);
+ new bool CheckPermission([In, ComAliasName("WUApiLib.AutomaticUpdatesUserType")] AutomaticUpdatesUserType userType, [In, ComAliasName("WUApiLib.AutomaticUpdatesPermissionType")] AutomaticUpdatesPermissionType permissionType);
///
///
@@ -2041,7 +2040,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-icategory-get_categoryid HRESULT get_CategoryID( BSTR *retval );
[DispId(1610743809)]
- string CategoryID
+ string? CategoryID
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
[return: MarshalAs(UnmanagedType.BStr)]
@@ -2055,7 +2054,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-icategory-get_children HRESULT get_Children(
// ICategoryCollection **retval );
[DispId(1610743810)]
- ICategoryCollection Children
+ ICategoryCollection? Children
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
[return: MarshalAs(UnmanagedType.Interface)]
@@ -2095,7 +2094,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-icategory-get_description HRESULT get_Description( BSTR *retval );
[DispId(1610743811)]
- string Description
+ string? Description
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
[return: MarshalAs(UnmanagedType.BStr)]
@@ -2136,7 +2135,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-icategory-get_image HRESULT get_Image( IImageInformation
// **retval );
[DispId(1610743812)]
- IImageInformation Image
+ IImageInformation? Image
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
[return: MarshalAs(UnmanagedType.Interface)]
@@ -2161,7 +2160,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-icategory-get_parent HRESULT get_Parent( ICategory **retval );
[DispId(1610743814)]
- ICategory Parent
+ ICategory? Parent
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743814)]
[return: MarshalAs(UnmanagedType.Interface)]
@@ -2190,7 +2189,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-icategory-get_updates HRESULT get_Updates( IUpdateCollection
// **retval );
[DispId(1610743816)]
- IUpdateCollection Updates
+ IUpdateCollection? Updates
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743816)]
[return: MarshalAs(UnmanagedType.Interface)]
@@ -2259,7 +2258,7 @@ public static partial class WUApi
// HRESULT Invoke( [in] IDownloadJob *downloadJob, [in] IDownloadCompletedCallbackArgs *callbackArgs );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
[PreserveSig]
- HRESULT Invoke([In][MarshalAs(UnmanagedType.Interface)] IDownloadJob downloadJob, [In][MarshalAs(UnmanagedType.Interface)] IDownloadCompletedCallbackArgs callbackArgs);
+ HRESULT Invoke([In, MarshalAs(UnmanagedType.Interface)] IDownloadJob downloadJob, [In, MarshalAs(UnmanagedType.Interface)] IDownloadCompletedCallbackArgs callbackArgs);
}
///
@@ -2504,7 +2503,7 @@ public static partial class WUApi
// HRESULT Invoke( [in] IDownloadJob *downloadJob, [in] IDownloadProgressChangedCallbackArgs *callbackArgs );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
[PreserveSig]
- HRESULT Invoke([In][MarshalAs(UnmanagedType.Interface)] IDownloadJob downloadJob, [In][MarshalAs(UnmanagedType.Interface)] IDownloadProgressChangedCallbackArgs callbackArgs);
+ HRESULT Invoke([In, MarshalAs(UnmanagedType.Interface)] IDownloadJob downloadJob, [In, MarshalAs(UnmanagedType.Interface)] IDownloadProgressChangedCallbackArgs callbackArgs);
}
/// Contains information about the change in the progress of an asynchronous download operation.
@@ -2531,7 +2530,7 @@ public static partial class WUApi
/// The IDownloadResult interface represents the result of a download operation.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-idownloadresult
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IDownloadResult")]
- [ComImport, Guid("DAA4FDD0-4727-4DBE-A1E7-745DCA317144")]
+ [ComImport, Guid("daa4fdd0-4727-4dbe-a1e7-745dca317144")]
public interface IDownloadResult
{
///
@@ -2539,10 +2538,10 @@ public static partial class WUApi
/// This property is read-only.
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-idownloadresult-get_hresult HRESULT get_HResult( LONG *retval );
- [DispId(1610743809)]
- HRESULT HResult
+ [DispId(0x60020001)]
+ int HResult
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
get;
}
@@ -2552,10 +2551,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-idownloadresult-get_resultcode HRESULT get_ResultCode(
// OperationResultCode *retval );
- [ComAliasName("WUApiLib.OperationResultCode"), DispId(1610743810)]
+ [ComAliasName("WUApiLib.OperationResultCode"), DispId(0x60020002)]
OperationResultCode ResultCode
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
[return: ComAliasName("WUApiLib.OperationResultCode")]
get;
}
@@ -2565,7 +2564,7 @@ public static partial class WUApi
/// An IUpdateDownloadResult interface that contains the results for the specified update.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-idownloadresult-getupdateresult HRESULT GetUpdateResult( [in]
// LONG updateIndex, [out] IUpdateDownloadResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[return: MarshalAs(UnmanagedType.Interface)]
IUpdateDownloadResult GetUpdateResult([In] int updateIndex);
}
@@ -2630,7 +2629,7 @@ public static partial class WUApi
/// Records the result for an update.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iinstallationagent
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IInstallationAgent")]
- [ComImport, Guid("925CBC18-A2EA-4648-BF1C-EC8BADCFE20A"), CoClass(typeof(InstallationAgent))]
+ [ComImport, Guid("925CBC18-A2EA-4648-BF1C-EC8BADCFE20A"), CoClass(typeof(InstallationAgentClass))]
public interface IInstallationAgent
{
/// Records the result for an update. The result is specified by an IStringCollection object.
@@ -2642,7 +2641,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationagent-recordinstallationresult HRESULT
// RecordInstallationResult( [in] BSTR installationResultCookie, [in] LONG hresult, [in] IStringCollection *extendedReportingData );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
- void RecordInstallationResult([In][MarshalAs(UnmanagedType.BStr)] string installationResultCookie, [In] HRESULT hresult, [In][MarshalAs(UnmanagedType.Interface)] IStringCollection extendedReportingData);
+ void RecordInstallationResult([In, MarshalAs(UnmanagedType.BStr)] string installationResultCookie, [In] HRESULT hresult, [In, MarshalAs(UnmanagedType.Interface)] IStringCollection extendedReportingData);
}
/// Represents the installation and uninstallation options of an update.
@@ -2730,7 +2729,7 @@ public static partial class WUApi
// IInstallationJob *installationJob, [in] IInstallationCompletedCallbackArgs *callbackArgs );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
[PreserveSig]
- HRESULT Invoke([In][MarshalAs(UnmanagedType.Interface)] IInstallationJob installationJob, [In][MarshalAs(UnmanagedType.Interface)] IInstallationCompletedCallbackArgs? callbackArgs);
+ HRESULT Invoke([In, MarshalAs(UnmanagedType.Interface)] IInstallationJob installationJob, [In, MarshalAs(UnmanagedType.Interface)] IInstallationCompletedCallbackArgs? callbackArgs);
}
///
@@ -2766,10 +2765,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationjob-get_asyncstate HRESULT get_AsyncState( VARIANT
// *retval );
- [DispId(1610743809)]
- object AsyncState
+ [DispId(0x60020001)]
+ object? AsyncState
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
[return: MarshalAs(UnmanagedType.Struct)]
get;
}
@@ -2783,10 +2782,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationjob-get_iscompleted HRESULT get_IsCompleted(
// VARIANT_BOOL *retval );
- [DispId(1610743810)]
+ [DispId(0x60020002)]
bool IsCompleted
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
get;
}
@@ -2796,10 +2795,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationjob-get_updates HRESULT get_Updates(
// IUpdateCollection **retval );
- [DispId(1610743811)]
+ [DispId(0x60020003)]
IUpdateCollection Updates
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[return: MarshalAs(UnmanagedType.Interface)]
get;
}
@@ -2810,7 +2809,7 @@ public static partial class WUApi
/// perform asynchronous WUA operations, see Guidelines for Asynchronous WUA Operations.
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationjob-cleanup HRESULT CleanUp();
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
void CleanUp();
/// Returns an IInstallationProgress interface that describes the current progress of an installation or uninstallation.
@@ -2821,13 +2820,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationjob-getprogress HRESULT GetProgress( [out]
// IInstallationProgress **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743813)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020005)]
[return: MarshalAs(UnmanagedType.Interface)]
IInstallationProgress GetProgress();
/// Makes a request to cancel the installation or uninstallation.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationjob-requestabort HRESULT RequestAbort();
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743814)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020006)]
void RequestAbort();
}
@@ -2846,10 +2845,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationprogress-get_currentupdateindex HRESULT
// get_CurrentUpdateIndex( LONG *retval );
- [DispId(1610743809)]
+ [DispId(0x60020001)]
int CurrentUpdateIndex
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
get;
}
@@ -2859,10 +2858,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationprogress-get_currentupdatepercentcomplete HRESULT
// get_CurrentUpdatePercentComplete( LONG *retval );
- [DispId(1610743810)]
+ [DispId(0x60020002)]
int CurrentUpdatePercentComplete
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
get;
}
@@ -2872,10 +2871,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationprogress-get_percentcomplete HRESULT
// get_PercentComplete( LONG *retval );
- [DispId(1610743811)]
+ [DispId(0x60020003)]
int PercentComplete
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
get;
}
@@ -2888,7 +2887,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationprogress-getupdateresult HRESULT GetUpdateResult(
// [in] LONG updateIndex, [out] IUpdateInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
[return: MarshalAs(UnmanagedType.Interface)]
IUpdateInstallationResult GetUpdateResult([In] int updateIndex);
}
@@ -2913,7 +2912,7 @@ public static partial class WUApi
// [in] IInstallationJob *installationJob, [in] IInstallationProgressChangedCallbackArgs *callbackArgs );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
[PreserveSig]
- HRESULT Invoke([In][MarshalAs(UnmanagedType.Interface)] IInstallationJob installationJob, [In][MarshalAs(UnmanagedType.Interface)] IInstallationProgressChangedCallbackArgs callbackArgs);
+ HRESULT Invoke([In, MarshalAs(UnmanagedType.Interface)] IInstallationJob installationJob, [In, MarshalAs(UnmanagedType.Interface)] IInstallationProgressChangedCallbackArgs callbackArgs);
}
///
@@ -2932,10 +2931,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationprogresschangedcallbackargs-get_progress HRESULT
// get_Progress( IInstallationProgress **retval );
- [DispId(1610743809)]
+ [DispId(0x60020001)]
IInstallationProgress Progress
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
[return: MarshalAs(UnmanagedType.Interface)]
get;
}
@@ -2953,10 +2952,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationresult-get_hresult HRESULT get_HResult( LONG
// *retval );
- [DispId(1610743809)]
- HRESULT HResult
+ [DispId(0x60020001)]
+ int HResult
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
get;
}
@@ -2968,10 +2967,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationresult-get_rebootrequired HRESULT
// get_RebootRequired( VARIANT_BOOL *retval );
- [DispId(1610743810)]
+ [DispId(0x60020002)]
bool RebootRequired
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
get;
}
@@ -2981,10 +2980,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationresult-get_resultcode HRESULT get_ResultCode(
// OperationResultCode *retval );
- [DispId(1610743811), ComAliasName("WUApiLib.OperationResultCode")]
+ [DispId(0x60020003), ComAliasName("WUApiLib.OperationResultCode")]
OperationResultCode ResultCode
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[return: ComAliasName("WUApiLib.OperationResultCode")]
get;
}
@@ -2994,7 +2993,7 @@ public static partial class WUApi
/// An interface that contains results for a specified update.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iinstallationresult-getupdateresult HRESULT GetUpdateResult(
// [in] LONG updateIndex, [out] IUpdateInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
[return: MarshalAs(UnmanagedType.Interface)]
IUpdateInstallationResult GetUpdateResult([In] int updateIndex);
}
@@ -3024,7 +3023,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateexception-get_hresult HRESULT get_HResult( LONG *retval );
[DispId(1610743809)]
- new HRESULT HResult
+ new int HResult
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
get;
@@ -3080,7 +3079,7 @@ public static partial class WUApi
// *searchJob, [in] ISearchCompletedCallbackArgs *callbackArgs );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime)]
[PreserveSig]
- HRESULT Invoke([In][MarshalAs(UnmanagedType.Interface)] ISearchJob searchJob, [In][MarshalAs(UnmanagedType.Interface)] ISearchCompletedCallbackArgs callbackArgs);
+ HRESULT Invoke([In] ISearchJob searchJob, [In] ISearchCompletedCallbackArgs callbackArgs);
}
///
@@ -3107,7 +3106,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-isearchjob-get_asyncstate HRESULT get_AsyncState( VARIANT
// *retval );
[DispId(1610743809)]
- object AsyncState
+ object? AsyncState
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
[return: MarshalAs(UnmanagedType.Struct)]
@@ -3212,7 +3211,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-istringcollection
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IStringCollection")]
- [ComImport, Guid("EFF90582-2DDC-480F-A06D-60F3FBC362C3"), CoClass(typeof(StringCollection))]
+ [ComImport, Guid("EFF90582-2DDC-480F-A06D-60F3FBC362C3"), CoClass(typeof(StringCollectionClass))]
public interface IStringCollection : IEnumerable
{
///
@@ -3274,7 +3273,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-istringcollection-add HRESULT Add( [in] BSTR value, [out] LONG
// *retval );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
- int Add([In][MarshalAs(UnmanagedType.BStr)] string value);
+ int Add([In, MarshalAs(UnmanagedType.BStr)] string value);
/// Removes all the elements from the collection.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-istringcollection-clear HRESULT Clear();
@@ -3295,7 +3294,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-istringcollection-insert HRESULT Insert( [in] LONG index, [in]
// BSTR value );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743814)]
- void Insert([In] int index, [In][MarshalAs(UnmanagedType.BStr)] string value);
+ void Insert([In] int index, [In, MarshalAs(UnmanagedType.BStr)] string value);
/// Removes the item at the specified index from the collection.
/// The index of the string to be removed.
@@ -3311,7 +3310,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-isysteminformation
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.ISystemInformation")]
- [ComImport, Guid("ADE87BF7-7B56-4275-8FAB-B9B0E591844B"), CoClass(typeof(SystemInformation))]
+ [ComImport, Guid("ADE87BF7-7B56-4275-8FAB-B9B0E591844B"), CoClass(typeof(SystemInformationClass))]
public interface ISystemInformation
{
///
diff --git a/PInvoke/WUApi/WUApi2.cs b/PInvoke/WUApi/WUApi2.cs
index 47e2cf47..51a7b03a 100644
--- a/PInvoke/WUApi/WUApi2.cs
+++ b/PInvoke/WUApi/WUApi2.cs
@@ -262,7 +262,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-get_handlerid HRESULT get_HandlerID( BSTR *retval );
[DispId(1610743819)]
- string HandlerID
+ string? HandlerID
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743819)]
[return: MarshalAs(UnmanagedType.BStr)]
@@ -868,7 +868,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-copyfromcache HRESULT CopyFromCache( [in] BSTR path,
// [in] VARIANT_BOOL toExtractCabFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743850)]
- void CopyFromCache([In][MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
+ void CopyFromCache([In, MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
///
/// Gets the suggested download priority of the update.
@@ -1154,7 +1154,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-get_handlerid HRESULT get_HandlerID( BSTR *retval );
[DispId(1610743819)]
- new string HandlerID
+ new string? HandlerID
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743819)]
[return: MarshalAs(UnmanagedType.BStr)]
@@ -1760,7 +1760,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-copyfromcache HRESULT CopyFromCache( [in] BSTR path,
// [in] VARIANT_BOOL toExtractCabFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743850)]
- new void CopyFromCache([In][MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
+ new void CopyFromCache([In, MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
///
/// Gets the suggested download priority of the update.
@@ -1874,7 +1874,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate2-copytocache HRESULT CopyToCache( [in]
// IStringCollection *pFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610809346)]
- void CopyToCache([In][MarshalAs(UnmanagedType.Interface)] IStringCollection pFiles);
+ void CopyToCache([In, MarshalAs(UnmanagedType.Interface)] IStringCollection pFiles);
}
/// Contains the properties and methods that are available to an update.
@@ -2132,7 +2132,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-get_handlerid HRESULT get_HandlerID( BSTR *retval );
[DispId(1610743819)]
- new string HandlerID
+ new string? HandlerID
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743819)]
[return: MarshalAs(UnmanagedType.BStr)]
@@ -2738,7 +2738,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-copyfromcache HRESULT CopyFromCache( [in] BSTR path,
// [in] VARIANT_BOOL toExtractCabFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743850)]
- new void CopyFromCache([In][MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
+ new void CopyFromCache([In, MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
///
/// Gets the suggested download priority of the update.
@@ -2852,7 +2852,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate2-copytocache HRESULT CopyToCache( [in]
// IStringCollection *pFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610809346)]
- new void CopyToCache([In][MarshalAs(UnmanagedType.Interface)] IStringCollection pFiles);
+ new void CopyToCache([In, MarshalAs(UnmanagedType.Interface)] IStringCollection pFiles);
///
/// Gets a Boolean value that indicates whether an update can be discovered only by browsing through the available updates.
@@ -3123,7 +3123,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-get_handlerid HRESULT get_HandlerID( BSTR *retval );
[DispId(1610743819)]
- new string HandlerID
+ new string? HandlerID
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743819)]
[return: MarshalAs(UnmanagedType.BStr)]
@@ -3729,7 +3729,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-copyfromcache HRESULT CopyFromCache( [in] BSTR path,
// [in] VARIANT_BOOL toExtractCabFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743850)]
- new void CopyFromCache([In][MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
+ new void CopyFromCache([In, MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
///
/// Gets the suggested download priority of the update.
@@ -3843,7 +3843,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate2-copytocache HRESULT CopyToCache( [in]
// IStringCollection *pFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610809346)]
- new void CopyToCache([In][MarshalAs(UnmanagedType.Interface)] IStringCollection pFiles);
+ new void CopyToCache([In, MarshalAs(UnmanagedType.Interface)] IStringCollection pFiles);
///
/// Gets a Boolean value that indicates whether an update can be discovered only by browsing through the available updates.
@@ -4135,7 +4135,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-get_handlerid HRESULT get_HandlerID( BSTR *retval );
[DispId(1610743819)]
- new string HandlerID
+ new string? HandlerID
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743819)]
[return: MarshalAs(UnmanagedType.BStr)]
@@ -4741,7 +4741,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-copyfromcache HRESULT CopyFromCache( [in] BSTR path,
// [in] VARIANT_BOOL toExtractCabFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743850)]
- new void CopyFromCache([In][MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
+ new void CopyFromCache([In, MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
///
/// Gets the suggested download priority of the update.
@@ -4855,7 +4855,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate2-copytocache HRESULT CopyToCache( [in]
// IStringCollection *pFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610809346)]
- new void CopyToCache([In][MarshalAs(UnmanagedType.Interface)] IStringCollection pFiles);
+ new void CopyToCache([In, MarshalAs(UnmanagedType.Interface)] IStringCollection pFiles);
///
/// Gets a Boolean value that indicates whether an update can be discovered only by browsing through the available updates.
@@ -4932,7 +4932,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdatecollection
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateCollection")]
- [ComImport, Guid("07F7438C-7709-4CA5-B518-91279288134E"), CoClass(typeof(UpdateCollection))]
+ [ComImport, Guid("07f7438c-7709-4ca5-b518-91279288134e"), CoClass(typeof(UpdateCollectionClass))/*, TypeLibType(TypeLibTypeFlags.FDispatchable | TypeLibTypeFlags.FHidden | TypeLibTypeFlags.FDual | TypeLibTypeFlags.FNonExtensible)*/]
public interface IUpdateCollection : IEnumerable
{
///
@@ -4968,10 +4968,10 @@ public static partial class WUApi
/// This property is read-only.
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatecollection-get_count HRESULT get_Count( LONG *retval );
- [DispId(1610743809)]
+ [DispId(0x60020001)]
int Count
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
get;
}
@@ -4981,10 +4981,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatecollection-get_readonly HRESULT get_ReadOnly(
// VARIANT_BOOL *retval );
- [DispId(1610743810)]
+ [DispId(0x60020002)]
bool ReadOnly
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
get;
}
@@ -4993,19 +4993,19 @@ public static partial class WUApi
/// The index of the added interface in the collection.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatecollection-add HRESULT Add( [in] IUpdate *value, [out]
// LONG *retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
- int Add([In][MarshalAs(UnmanagedType.Interface)] IUpdate value);
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
+ int Add([In, MarshalAs(UnmanagedType.Interface)] IUpdate value);
/// Removes all the elements from the collection.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatecollection-clear HRESULT Clear();
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
void Clear();
/// Creates a shallow read/write copy of the collection.
/// A shallow read/write copy of the collection.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatecollection-copy HRESULT Copy( [out] IUpdateCollection
// **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743813)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020005)]
[return: MarshalAs(UnmanagedType.Interface)]
IUpdateCollection Copy();
@@ -5014,13 +5014,13 @@ public static partial class WUApi
/// The IUpdate interface that will be inserted.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatecollection-insert HRESULT Insert( [in] LONG index, [in]
// IUpdate *value );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743814)]
- void Insert([In] int index, [In][MarshalAs(UnmanagedType.Interface)] IUpdate value);
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020006)]
+ void Insert([In] int index, [In, MarshalAs(UnmanagedType.Interface)] IUpdate value);
/// Removes the item at the specified index from the collection.
/// The index of the interface to be removed.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatecollection-removeat HRESULT RemoveAt( [in] LONG index );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743815)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020007)]
void RemoveAt([In] int index);
}
}
\ No newline at end of file
diff --git a/PInvoke/WUApi/WUApi3.cs b/PInvoke/WUApi/WUApi3.cs
index 6a797170..fc0970b2 100644
--- a/PInvoke/WUApi/WUApi3.cs
+++ b/PInvoke/WUApi/WUApi3.cs
@@ -116,7 +116,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdatedownloader
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateDownloader")]
- [ComImport, Guid("68F1C6F9-7ECC-4666-A464-247FE12496C3"), CoClass(typeof(UpdateDownloader))]
+ [ComImport, Guid("68f1c6f9-7ecc-4666-a464-247fe12496c3"), CoClass(typeof(UpdateDownloaderClass))]
public interface IUpdateDownloader
{
///
@@ -126,13 +126,13 @@ public static partial class WUApi
/// Returns the value Unknown if the client application has not set the property.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatedownloader-get_clientapplicationid HRESULT
// get_ClientApplicationID( BSTR *retval );
- [DispId(1610743809)]
- string ClientApplicationID
+ [DispId(0x60020001)]
+ string? ClientApplicationID
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
[return: MarshalAs(UnmanagedType.BStr)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
[param: In, MarshalAs(UnmanagedType.BStr)]
set;
}
@@ -147,12 +147,12 @@ public static partial class WUApi
/// This method returns WU_E_INVALID_OPERATION if the object that is implementing the interface is locked down.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatedownloader-get_isforced HRESULT get_IsForced(
// VARIANT_BOOL *retval );
- [DispId(1610743810)]
+ [DispId(0x60020002)]
bool IsForced
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
[param: In]
set;
}
@@ -163,13 +163,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatedownloader-get_priority HRESULT get_Priority(
// DownloadPriority *retval );
- [DispId(1610743811), ComAliasName("WUApiLib.DownloadPriority")]
+ [DispId(0x60020003), ComAliasName("WUApiLib.DownloadPriority")]
DownloadPriority Priority
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[return: ComAliasName("WUApiLib.DownloadPriority")]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[param: In, ComAliasName("WUApiLib.DownloadPriority")]
set;
}
@@ -180,13 +180,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatedownloader-put_updates HRESULT put_Updates(
// IUpdateCollection *value );
- [DispId(1610743812)]
+ [DispId(0x60020004)]
IUpdateCollection Updates
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
[return: MarshalAs(UnmanagedType.Interface)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
[param: In, MarshalAs(UnmanagedType.Interface)]
set;
}
@@ -240,9 +240,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatedownloader-begindownload HRESULT BeginDownload( [in]
// IUnknown *onProgressChanged, [in] IUnknown *onCompleted, [in] VARIANT state, [out] IDownloadJob **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743813)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020005)]
[return: MarshalAs(UnmanagedType.Interface)]
- IDownloadJob BeginDownload([In, MarshalAs(UnmanagedType.IUnknown)] object onProgressChanged, [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object state);
+ IDownloadJob BeginDownload([In, MarshalAs(UnmanagedType.IUnknown)] object onProgressChanged,
+ [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object? state);
/// Starts a synchronous download of the content files that are associated with the updates.
/// An IDownloadResult interface that contains result codes for the download.
@@ -256,7 +257,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatedownloader-download HRESULT Download( [out]
// IDownloadResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743814)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020006)]
[return: MarshalAs(UnmanagedType.Interface)]
IDownloadResult Download();
@@ -272,7 +273,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatedownloader-enddownload HRESULT EndDownload( [in]
// IDownloadJob *value, [out] IDownloadResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743815)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020007)]
[return: MarshalAs(UnmanagedType.Interface)]
IDownloadResult EndDownload([In, MarshalAs(UnmanagedType.Interface)] IDownloadJob value);
}
@@ -280,7 +281,7 @@ public static partial class WUApi
/// Contains the properties that indicate the status of a download operation for an update.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdatedownloadresult
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateDownloadResult")]
- [ComImport, Guid("BF99AF76-B575-42AD-8AA4-33CBB5477AF1")]
+ [ComImport, Guid("bf99af76-b575-42ad-8aa4-33cbb5477af1")]
public interface IUpdateDownloadResult
{
///
@@ -289,10 +290,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatedownloadresult-get_hresult HRESULT get_HResult( LONG
// *retval );
- [DispId(1610743809)]
- HRESULT HResult
+ [DispId(0x60020001)]
+ int HResult
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
get;
}
@@ -302,10 +303,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatedownloadresult-get_resultcode HRESULT get_ResultCode(
// OperationResultCode *retval );
- [ComAliasName("WUApiLib.OperationResultCode"), DispId(1610743810)]
+ [ComAliasName("WUApiLib.OperationResultCode"), DispId(0x60020002)]
OperationResultCode ResultCode
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
[return: ComAliasName("WUApiLib.OperationResultCode")]
get;
}
@@ -346,7 +347,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateexception-get_hresult HRESULT get_HResult( LONG *retval );
[DispId(1610743809)]
- HRESULT HResult
+ int HResult
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
get;
@@ -455,7 +456,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatehistoryentry-get_hresult HRESULT get_HResult( LONG
// *retval );
[DispId(1610743811)]
- HRESULT HResult
+ int HResult
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
get;
@@ -749,7 +750,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdatehistoryentry-get_hresult HRESULT get_HResult( LONG
// *retval );
[DispId(1610743811)]
- new HRESULT HResult
+ new int HResult
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
get;
@@ -1076,11 +1077,8 @@ public static partial class WUApi
[ComImport, Guid("46297823-9940-4C09-AED9-CD3EA6D05968")]
public interface IUpdateIdentity
{
- ///
- /// Gets the revision-independent identifier of an update.
- /// This property is read-only.
- ///
- // https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateidentity-get_updateid HRESULT get_UpdateID( BSTR *retval );
+ /// Gest the revision number of the update.
+ // https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-uamg/e9c2b583-44a9-4300-9650-871c15c07a65
[DispId(1610743810)]
int RevisionNumber
{
@@ -1088,10 +1086,7 @@ public static partial class WUApi
get;
}
- ///
- /// Gets the revision-independent identifier of an update.
- /// This property is read-only.
- ///
+ /// Gets the revision-independent identifier of an update.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateidentity-get_updateid HRESULT get_UpdateID( BSTR *retval );
[DispId(1610743811)]
string UpdateID
@@ -1114,10 +1109,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstallationresult-get_hresult HRESULT get_HResult( LONG
// *retval );
- [DispId(1610743809)]
- HRESULT HResult
+ [DispId(0x60020001)]
+ int HResult
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
get;
}
@@ -1129,10 +1124,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstallationresult-get_rebootrequired HRESULT
// get_RebootRequired( VARIANT_BOOL *retval );
- [DispId(1610743810)]
+ [DispId(0x60020002)]
bool RebootRequired
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
get;
}
@@ -1142,10 +1137,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstallationresult-get_resultcode HRESULT
// get_ResultCode( OperationResultCode *retval );
- [ComAliasName("WUApiLib.OperationResultCode"), DispId(1610743811)]
+ [ComAliasName("WUApiLib.OperationResultCode"), DispId(0x60020003)]
OperationResultCode ResultCode
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[return: ComAliasName("WUApiLib.OperationResultCode")]
get;
}
@@ -1158,7 +1153,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdateinstaller
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateInstaller")]
- [ComImport, ComConversionLoss, Guid("7B929C68-CCDC-4226-96B1-8724600B54C2")]
+ [ComImport, ComConversionLoss, Guid("7b929c68-ccdc-4226-96b1-8724600b54c2"), CoClass(typeof(UpdateInstallerClass))]
public interface IUpdateInstaller
{
///
@@ -1168,13 +1163,13 @@ public static partial class WUApi
/// Returns the Unknown value if the client application has not set the property.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-put_clientapplicationid HRESULT
// put_ClientApplicationID( BSTR value );
- [DispId(1610743809)]
- string ClientApplicationID
+ [DispId(0x60020001)]
+ string? ClientApplicationID
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
[return: MarshalAs(UnmanagedType.BStr)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
[param: In, MarshalAs(UnmanagedType.BStr)]
set;
}
@@ -1197,12 +1192,12 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-put_isforced HRESULT put_IsForced(
// VARIANT_BOOL value );
- [DispId(1610743810)]
+ [DispId(0x60020002)]
bool IsForced
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
[param: In]
set;
}
@@ -1216,13 +1211,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_parenthwnd HRESULT get_ParentHwnd( HWND
// *retval );
- [ComAliasName("WUApiLib.wireHWND"), DispId(1610743811)]
+ [ComAliasName("WUApiLib.wireHWND"), DispId(0x60020003)]
HWND ParentHwnd
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[return: ComAliasName("WUApiLib.wireHWND")]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[param: In, ComAliasName("WUApiLib.wireHWND")]
set;
}
@@ -1236,13 +1231,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_parentwindow HRESULT get_ParentWindow(
// IUnknown **retval );
- [DispId(1610743812)]
- object parentWindow
+ [DispId(0x60020004)]
+ object? parentWindow
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
[return: MarshalAs(UnmanagedType.IUnknown)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
[param: In, MarshalAs(UnmanagedType.IUnknown)]
set;
}
@@ -1253,13 +1248,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_updates HRESULT get_Updates(
// IUpdateCollection **retval );
- [DispId(1610743813)]
+ [DispId(0x60020005)]
IUpdateCollection Updates
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743813)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020005)]
[return: MarshalAs(UnmanagedType.Interface)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743813)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020005)]
[param: In, MarshalAs(UnmanagedType.Interface)]
set;
}
@@ -1292,10 +1287,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-begininstall HRESULT BeginInstall( [in]
// IUnknown *onProgressChanged, [in] IUnknown *onCompleted, [in] VARIANT state, [out] IInstallationJob **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743814)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020006)]
[return: MarshalAs(UnmanagedType.Interface)]
IInstallationJob BeginInstall([In, MarshalAs(UnmanagedType.IUnknown)] object onProgressChanged,
- [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object state);
+ [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object? state);
/// Starts an asynchronous uninstallation of the updates.
///
@@ -1325,10 +1320,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-beginuninstall HRESULT BeginUninstall( [in]
// IUnknown *onProgressChanged, [in] IUnknown *onCompleted, [in] VARIANT state, [out] IInstallationJob **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743815)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020007)]
[return: MarshalAs(UnmanagedType.Interface)]
IInstallationJob BeginUninstall([In, MarshalAs(UnmanagedType.IUnknown)] object onProgressChanged,
- [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object state);
+ [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object? state);
/// Completes an asynchronous installation of the updates.
/// The IInstallationJob interface that is returned by the BeginInstall method.
@@ -1339,7 +1334,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-endinstall HRESULT EndInstall( [in]
// IInstallationJob *value, [out] IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743816)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020008)]
[return: MarshalAs(UnmanagedType.Interface)]
IInstallationResult EndInstall([In, MarshalAs(UnmanagedType.Interface)] IInstallationJob value);
@@ -1352,7 +1347,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-enduninstall HRESULT EndUninstall( [in]
// IInstallationJob *value, [out] IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743817)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020009)]
[return: MarshalAs(UnmanagedType.Interface)]
IInstallationResult EndUninstall([In, MarshalAs(UnmanagedType.Interface)] IInstallationJob value);
@@ -1366,7 +1361,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-install HRESULT Install( [out]
// IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743818)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000a)]
[return: MarshalAs(UnmanagedType.Interface)]
IInstallationResult Install();
@@ -1385,7 +1380,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-runwizard HRESULT RunWizard( [in, optional]
// BSTR dialogTitle, [out] IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743819)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000b)]
[return: MarshalAs(UnmanagedType.Interface)]
IInstallationResult RunWizard([In, MarshalAs(UnmanagedType.BStr)] string dialogTitle = "");
@@ -1404,10 +1399,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_isbusy HRESULT get_IsBusy( VARIANT_BOOL
// *retval );
- [DispId(1610743820)]
+ [DispId(0x6002000c)]
bool IsBusy
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743820)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000c)]
get;
}
@@ -1422,7 +1417,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-uninstall HRESULT Uninstall( [out]
// IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743821)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000d)]
[return: MarshalAs(UnmanagedType.Interface)]
IInstallationResult Uninstall();
@@ -1432,12 +1427,12 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-put_allowsourceprompts HRESULT
// put_AllowSourcePrompts( VARIANT_BOOL value );
- [DispId(1610743822)]
+ [DispId(0x6002000e)]
bool AllowSourcePrompts
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743822)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000e)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743822)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000e)]
[param: In]
set;
}
@@ -1448,10 +1443,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_rebootrequiredbeforeinstallation HRESULT
// get_RebootRequiredBeforeInstallation( VARIANT_BOOL *retval );
- [DispId(1610743823)]
+ [DispId(0x6002000f)]
bool RebootRequiredBeforeInstallation
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743823)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000f)]
get;
}
}
@@ -1463,7 +1458,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdateinstaller2
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateInstaller2")]
- [ComImport, Guid("3442D4FE-224D-4CEE-98CF-30E0C4D229E6"), CoClass(typeof(UpdateInstaller))]
+ [ComImport, Guid("3442d4fe-224d-4cee-98cf-30e0c4d229e6"), CoClass(typeof(UpdateInstallerClass))]
public interface IUpdateInstaller2 : IUpdateInstaller
{
///
@@ -1473,13 +1468,13 @@ public static partial class WUApi
/// Returns the Unknown value if the client application has not set the property.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-put_clientapplicationid HRESULT
// put_ClientApplicationID( BSTR value );
- [DispId(1610743809)]
- new string ClientApplicationID
+ [DispId(0x60020001)]
+ new string? ClientApplicationID
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
[return: MarshalAs(UnmanagedType.BStr)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
[param: In, MarshalAs(UnmanagedType.BStr)]
set;
}
@@ -1502,12 +1497,12 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-put_isforced HRESULT put_IsForced(
// VARIANT_BOOL value );
- [DispId(1610743810)]
+ [DispId(0x60020002)]
new bool IsForced
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
[param: In]
set;
}
@@ -1521,13 +1516,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_parenthwnd HRESULT get_ParentHwnd( HWND
// *retval );
- [ComAliasName("WUApiLib.wireHWND"), DispId(1610743811)]
+ [ComAliasName("WUApiLib.wireHWND"), DispId(0x60020003)]
new HWND ParentHwnd
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[return: ComAliasName("WUApiLib.wireHWND")]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[param: In, ComAliasName("WUApiLib.wireHWND")]
set;
}
@@ -1541,13 +1536,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_parentwindow HRESULT get_ParentWindow(
// IUnknown **retval );
- [DispId(1610743812)]
- new object parentWindow
+ [DispId(0x60020004)]
+ new object? parentWindow
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
[return: MarshalAs(UnmanagedType.IUnknown)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
[param: In, MarshalAs(UnmanagedType.IUnknown)]
set;
}
@@ -1558,13 +1553,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_updates HRESULT get_Updates(
// IUpdateCollection **retval );
- [DispId(1610743813)]
+ [DispId(0x60020005)]
new IUpdateCollection Updates
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743813)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020005)]
[return: MarshalAs(UnmanagedType.Interface)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743813)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020005)]
[param: In, MarshalAs(UnmanagedType.Interface)]
set;
}
@@ -1597,10 +1592,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-begininstall HRESULT BeginInstall( [in]
// IUnknown *onProgressChanged, [in] IUnknown *onCompleted, [in] VARIANT state, [out] IInstallationJob **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743814)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020006)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationJob BeginInstall([In, MarshalAs(UnmanagedType.IUnknown)] object onProgressChanged,
- [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object state);
+ [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object? state);
/// Starts an asynchronous uninstallation of the updates.
///
@@ -1630,10 +1625,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-beginuninstall HRESULT BeginUninstall( [in]
// IUnknown *onProgressChanged, [in] IUnknown *onCompleted, [in] VARIANT state, [out] IInstallationJob **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743815)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020007)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationJob BeginUninstall([In, MarshalAs(UnmanagedType.IUnknown)] object onProgressChanged,
- [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object state);
+ [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object? state);
/// Completes an asynchronous installation of the updates.
/// The IInstallationJob interface that is returned by the BeginInstall method.
@@ -1644,7 +1639,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-endinstall HRESULT EndInstall( [in]
// IInstallationJob *value, [out] IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743816)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020008)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult EndInstall([In, MarshalAs(UnmanagedType.Interface)] IInstallationJob value);
@@ -1657,7 +1652,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-enduninstall HRESULT EndUninstall( [in]
// IInstallationJob *value, [out] IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743817)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020009)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult EndUninstall([In, MarshalAs(UnmanagedType.Interface)] IInstallationJob value);
@@ -1671,7 +1666,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-install HRESULT Install( [out]
// IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743818)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000a)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult Install();
@@ -1690,7 +1685,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-runwizard HRESULT RunWizard( [in, optional]
// BSTR dialogTitle, [out] IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743819)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000b)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult RunWizard([In, MarshalAs(UnmanagedType.BStr)] string dialogTitle = "");
@@ -1709,10 +1704,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_isbusy HRESULT get_IsBusy( VARIANT_BOOL
// *retval );
- [DispId(1610743820)]
+ [DispId(0x6002000c)]
new bool IsBusy
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743820)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000c)]
get;
}
@@ -1727,7 +1722,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-uninstall HRESULT Uninstall( [out]
// IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743821)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000d)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult Uninstall();
@@ -1737,12 +1732,12 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-put_allowsourceprompts HRESULT
// put_AllowSourcePrompts( VARIANT_BOOL value );
- [DispId(1610743822)]
+ [DispId(0x6002000e)]
new bool AllowSourcePrompts
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743822)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000e)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743822)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000e)]
[param: In]
set;
}
@@ -1753,10 +1748,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_rebootrequiredbeforeinstallation HRESULT
// get_RebootRequiredBeforeInstallation( VARIANT_BOOL *retval );
- [DispId(1610743823)]
+ [DispId(0x6002000f)]
new bool RebootRequiredBeforeInstallation
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743823)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000f)]
get;
}
@@ -1770,12 +1765,12 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller2-put_forcequiet HRESULT put_ForceQuiet(
// VARIANT_BOOL value );
- [DispId(1610809345)]
+ [DispId(0x60030001)]
bool ForceQuiet
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610809345)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60030001)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610809345)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60030001)]
[param: In]
set;
}
@@ -1787,7 +1782,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdateinstaller3
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateInstaller3")]
- [ComImport, Guid("16D11C35-099A-48D0-8338-5FAE64047F8E")]
+ [ComImport, Guid("16d11c35-099a-48d0-8338-5fae64047f8e")]
public interface IUpdateInstaller3 : IUpdateInstaller2
{
///
@@ -1797,13 +1792,13 @@ public static partial class WUApi
/// Returns the Unknown value if the client application has not set the property.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-put_clientapplicationid HRESULT
// put_ClientApplicationID( BSTR value );
- [DispId(1610743809)]
- new string ClientApplicationID
+ [DispId(0x60020001)]
+ new string? ClientApplicationID
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
[return: MarshalAs(UnmanagedType.BStr)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
[param: In, MarshalAs(UnmanagedType.BStr)]
set;
}
@@ -1826,12 +1821,12 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-put_isforced HRESULT put_IsForced(
// VARIANT_BOOL value );
- [DispId(1610743810)]
+ [DispId(0x60020002)]
new bool IsForced
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
[param: In]
set;
}
@@ -1845,13 +1840,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_parenthwnd HRESULT get_ParentHwnd( HWND
// *retval );
- [ComAliasName("WUApiLib.wireHWND"), DispId(1610743811)]
+ [ComAliasName("WUApiLib.wireHWND"), DispId(0x60020003)]
new HWND ParentHwnd
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[return: ComAliasName("WUApiLib.wireHWND")]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[param: In, ComAliasName("WUApiLib.wireHWND")]
set;
}
@@ -1865,13 +1860,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_parentwindow HRESULT get_ParentWindow(
// IUnknown **retval );
- [DispId(1610743812)]
- new object parentWindow
+ [DispId(0x60020004)]
+ new object? parentWindow
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
[return: MarshalAs(UnmanagedType.IUnknown)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
[param: In, MarshalAs(UnmanagedType.IUnknown)]
set;
}
@@ -1882,13 +1877,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_updates HRESULT get_Updates(
// IUpdateCollection **retval );
- [DispId(1610743813)]
+ [DispId(0x60020005)]
new IUpdateCollection Updates
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743813)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020005)]
[return: MarshalAs(UnmanagedType.Interface)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743813)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020005)]
[param: In, MarshalAs(UnmanagedType.Interface)]
set;
}
@@ -1921,10 +1916,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-begininstall HRESULT BeginInstall( [in]
// IUnknown *onProgressChanged, [in] IUnknown *onCompleted, [in] VARIANT state, [out] IInstallationJob **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743814)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020006)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationJob BeginInstall([In, MarshalAs(UnmanagedType.IUnknown)] object onProgressChanged,
- [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object state);
+ [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object? state);
/// Starts an asynchronous uninstallation of the updates.
///
@@ -1954,10 +1949,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-beginuninstall HRESULT BeginUninstall( [in]
// IUnknown *onProgressChanged, [in] IUnknown *onCompleted, [in] VARIANT state, [out] IInstallationJob **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743815)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020007)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationJob BeginUninstall([In, MarshalAs(UnmanagedType.IUnknown)] object onProgressChanged,
- [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object state);
+ [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object? state);
/// Completes an asynchronous installation of the updates.
/// The IInstallationJob interface that is returned by the BeginInstall method.
@@ -1968,7 +1963,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-endinstall HRESULT EndInstall( [in]
// IInstallationJob *value, [out] IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743816)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020008)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult EndInstall([In, MarshalAs(UnmanagedType.Interface)] IInstallationJob value);
@@ -1981,7 +1976,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-enduninstall HRESULT EndUninstall( [in]
// IInstallationJob *value, [out] IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743817)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020009)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult EndUninstall([In, MarshalAs(UnmanagedType.Interface)] IInstallationJob value);
@@ -1995,7 +1990,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-install HRESULT Install( [out]
// IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743818)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000a)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult Install();
@@ -2014,7 +2009,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-runwizard HRESULT RunWizard( [in, optional]
// BSTR dialogTitle, [out] IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743819)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000b)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult RunWizard([In, MarshalAs(UnmanagedType.BStr)] string dialogTitle = "");
@@ -2033,10 +2028,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_isbusy HRESULT get_IsBusy( VARIANT_BOOL
// *retval );
- [DispId(1610743820)]
+ [DispId(0x6002000c)]
new bool IsBusy
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743820)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000c)]
get;
}
@@ -2051,7 +2046,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-uninstall HRESULT Uninstall( [out]
// IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743821)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000d)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult Uninstall();
@@ -2061,12 +2056,12 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-put_allowsourceprompts HRESULT
// put_AllowSourcePrompts( VARIANT_BOOL value );
- [DispId(1610743822)]
+ [DispId(0x6002000e)]
new bool AllowSourcePrompts
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743822)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000e)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743822)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000e)]
[param: In]
set;
}
@@ -2077,10 +2072,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_rebootrequiredbeforeinstallation HRESULT
// get_RebootRequiredBeforeInstallation( VARIANT_BOOL *retval );
- [DispId(1610743823)]
+ [DispId(0x6002000f)]
new bool RebootRequiredBeforeInstallation
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743823)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000f)]
get;
}
@@ -2094,12 +2089,12 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller2-put_forcequiet HRESULT put_ForceQuiet(
// VARIANT_BOOL value );
- [DispId(1610809345)]
+ [DispId(0x60030001)]
new bool ForceQuiet
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610809345)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60030001)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610809345)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60030001)]
[param: In]
set;
}
@@ -2110,12 +2105,12 @@ public static partial class WUApi
/// True if the installer will attempt to close applications.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller3-get_attemptcloseappsifnecessary HRESULT
// get_AttemptCloseAppsIfNecessary( [out] VARIANT_BOOL *retval );
- [DispId(1610874881)]
+ [DispId(0x60040001)]
bool AttemptCloseAppsIfNecessary
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610874881)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60040001)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610874881)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60040001)]
[param: In]
set;
}
@@ -2124,7 +2119,7 @@ public static partial class WUApi
/// Provides methods to finalize updates that were previously staged or installed.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdateinstaller4
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateInstaller4")]
- [ComImport, Guid("EF8208EA-2304-492D-9109-23813B0958E1")]
+ [ComImport, Guid("EF8208EA-2304-492D-9109-23813B0958E1"), CoClass(typeof(UpdateInstallerClass))]
public interface IUpdateInstaller4 : IUpdateInstaller3
{
///
@@ -2134,13 +2129,13 @@ public static partial class WUApi
/// Returns the Unknown value if the client application has not set the property.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-put_clientapplicationid HRESULT
// put_ClientApplicationID( BSTR value );
- [DispId(1610743809)]
- new string ClientApplicationID
+ [DispId(0x60020001)]
+ new string? ClientApplicationID
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
[return: MarshalAs(UnmanagedType.BStr)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743809)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020001)]
[param: In, MarshalAs(UnmanagedType.BStr)]
set;
}
@@ -2163,12 +2158,12 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-put_isforced HRESULT put_IsForced(
// VARIANT_BOOL value );
- [DispId(1610743810)]
+ [DispId(0x60020002)]
new bool IsForced
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020002)]
[param: In]
set;
}
@@ -2182,13 +2177,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_parenthwnd HRESULT get_ParentHwnd( HWND
// *retval );
- [ComAliasName("WUApiLib.wireHWND"), DispId(1610743811)]
+ [ComAliasName("WUApiLib.wireHWND"), DispId(0x60020003)]
new HWND ParentHwnd
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[return: ComAliasName("WUApiLib.wireHWND")]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743811)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020003)]
[param: In, ComAliasName("WUApiLib.wireHWND")]
set;
}
@@ -2202,13 +2197,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_parentwindow HRESULT get_ParentWindow(
// IUnknown **retval );
- [DispId(1610743812)]
- new object parentWindow
+ [DispId(0x60020004)]
+ new object? parentWindow
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
[return: MarshalAs(UnmanagedType.IUnknown)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743812)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020004)]
[param: In, MarshalAs(UnmanagedType.IUnknown)]
set;
}
@@ -2219,13 +2214,13 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_updates HRESULT get_Updates(
// IUpdateCollection **retval );
- [DispId(1610743813)]
+ [DispId(0x60020005)]
new IUpdateCollection Updates
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743813)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020005)]
[return: MarshalAs(UnmanagedType.Interface)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743813)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020005)]
[param: In, MarshalAs(UnmanagedType.Interface)]
set;
}
@@ -2258,10 +2253,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-begininstall HRESULT BeginInstall( [in]
// IUnknown *onProgressChanged, [in] IUnknown *onCompleted, [in] VARIANT state, [out] IInstallationJob **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743814)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020006)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationJob BeginInstall([In, MarshalAs(UnmanagedType.IUnknown)] object onProgressChanged,
- [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object state);
+ [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object? state);
/// Starts an asynchronous uninstallation of the updates.
///
@@ -2291,10 +2286,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-beginuninstall HRESULT BeginUninstall( [in]
// IUnknown *onProgressChanged, [in] IUnknown *onCompleted, [in] VARIANT state, [out] IInstallationJob **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743815)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020007)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationJob BeginUninstall([In, MarshalAs(UnmanagedType.IUnknown)] object onProgressChanged,
- [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object state);
+ [In, MarshalAs(UnmanagedType.IUnknown)] object onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object? state);
/// Completes an asynchronous installation of the updates.
/// The IInstallationJob interface that is returned by the BeginInstall method.
@@ -2305,7 +2300,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-endinstall HRESULT EndInstall( [in]
// IInstallationJob *value, [out] IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743816)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020008)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult EndInstall([In, MarshalAs(UnmanagedType.Interface)] IInstallationJob value);
@@ -2318,7 +2313,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-enduninstall HRESULT EndUninstall( [in]
// IInstallationJob *value, [out] IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743817)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60020009)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult EndUninstall([In, MarshalAs(UnmanagedType.Interface)] IInstallationJob value);
@@ -2332,7 +2327,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-install HRESULT Install( [out]
// IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743818)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000a)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult Install();
@@ -2351,7 +2346,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-runwizard HRESULT RunWizard( [in, optional]
// BSTR dialogTitle, [out] IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743819)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000b)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult RunWizard([In, MarshalAs(UnmanagedType.BStr)] string dialogTitle = "");
@@ -2370,10 +2365,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_isbusy HRESULT get_IsBusy( VARIANT_BOOL
// *retval );
- [DispId(1610743820)]
+ [DispId(0x6002000c)]
new bool IsBusy
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743820)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000c)]
get;
}
@@ -2388,7 +2383,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-uninstall HRESULT Uninstall( [out]
// IInstallationResult **retval );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743821)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000d)]
[return: MarshalAs(UnmanagedType.Interface)]
new IInstallationResult Uninstall();
@@ -2398,12 +2393,12 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-put_allowsourceprompts HRESULT
// put_AllowSourcePrompts( VARIANT_BOOL value );
- [DispId(1610743822)]
+ [DispId(0x6002000e)]
new bool AllowSourcePrompts
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743822)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000e)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743822)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000e)]
[param: In]
set;
}
@@ -2414,10 +2409,10 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller-get_rebootrequiredbeforeinstallation HRESULT
// get_RebootRequiredBeforeInstallation( VARIANT_BOOL *retval );
- [DispId(1610743823)]
+ [DispId(0x6002000f)]
new bool RebootRequiredBeforeInstallation
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743823)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x6002000f)]
get;
}
@@ -2431,12 +2426,12 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller2-put_forcequiet HRESULT put_ForceQuiet(
// VARIANT_BOOL value );
- [DispId(1610809345)]
+ [DispId(0x60030001)]
new bool ForceQuiet
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610809345)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60030001)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610809345)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60030001)]
[param: In]
set;
}
@@ -2447,12 +2442,12 @@ public static partial class WUApi
/// True if the installer will attempt to close applications.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller3-get_attemptcloseappsifnecessary HRESULT
// get_AttemptCloseAppsIfNecessary( [out] VARIANT_BOOL *retval );
- [DispId(1610874881)]
+ [DispId(0x60040001)]
new bool AttemptCloseAppsIfNecessary
{
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610874881)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60040001)]
get;
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610874881)]
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60040001)]
[param: In]
set;
}
@@ -2475,8 +2470,8 @@ public static partial class WUApi
/// Commit is safe to call prior to reboot for any other types of updates as well.
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateinstaller4-commit HRESULT Commit( DWORD dwFlags );
- [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610874882)]
- void Commit([In] uint dwFlags = 0);
+ [MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(0x60040002)]
+ void Commit([In] uint dwFlags);
}
/// Restricts access to methods and properties of objects that implements the method of this interface.
@@ -2571,7 +2566,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdatesearcher
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateSearcher")]
- [ComImport, Guid("8F45ABF1-F9AE-4B95-A933-F0F66E5056EA"), CoClass(typeof(UpdateSearcher))]
+ [ComImport, Guid("8F45ABF1-F9AE-4B95-A933-F0F66E5056EA"), CoClass(typeof(UpdateSearcherClass))]
public interface IUpdateSearcher
{
///
@@ -2680,7 +2675,7 @@ public static partial class WUApi
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743816)]
[return: MarshalAs(UnmanagedType.Interface)]
ISearchJob BeginSearch([In, MarshalAs(UnmanagedType.BStr)] string criteria,
- [In, MarshalAs(UnmanagedType.IUnknown)] ISearchCompletedCallback onCompleted, [In, MarshalAs(UnmanagedType.Struct)] object state);
+ [In] ISearchCompletedCallback onCompleted, [In, Optional, MarshalAs(UnmanagedType.Struct)] object? state);
/// Completes an asynchronous search for updates.
/// The ISearchJob interface that the BeginSearch method returns.
@@ -2964,7 +2959,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdatesearcher2
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateSearcher2")]
- [ComImport, Guid("4CBDCB2D-1589-4BEB-BD1C-3E582FF0ADD0"), CoClass(typeof(UpdateSearcher))]
+ [ComImport, Guid("4CBDCB2D-1589-4BEB-BD1C-3E582FF0ADD0"), CoClass(typeof(UpdateSearcherClass))]
public interface IUpdateSearcher2 : IUpdateSearcher
{
///
@@ -3376,7 +3371,7 @@ public static partial class WUApi
/// Searches for updates on a server.
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdatesearcher3
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateSearcher3")]
- [ComImport, Guid("04C6895D-EAF2-4034-97F3-311DE9BE413A"), CoClass(typeof(UpdateSearcher))]
+ [ComImport, Guid("04C6895D-EAF2-4034-97F3-311DE9BE413A"), CoClass(typeof(UpdateSearcherClass))]
public interface IUpdateSearcher3 : IUpdateSearcher2
{
///
@@ -3845,7 +3840,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateservice-get_expirationdate HRESULT get_ExpirationDate(
// DATE *retval );
[DispId(1610743810)]
- DateTime ExpirationDate
+ DateTime? ExpirationDate
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
get;
@@ -3924,7 +3919,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateservice-get_serviceid HRESULT get_ServiceID( BSTR
// *retval );
[DispId(1610743816)]
- string? ServiceID
+ string ServiceID
{
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743816)]
[return: MarshalAs(UnmanagedType.BStr)]
diff --git a/PInvoke/WUApi/WUApi4.cs b/PInvoke/WUApi/WUApi4.cs
index 5fbbe637..81d214f0 100644
--- a/PInvoke/WUApi/WUApi4.cs
+++ b/PInvoke/WUApi/WUApi4.cs
@@ -10,7 +10,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdateservicemanager
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateServiceManager")]
- [ComImport, Guid("23857E3C-02BA-44A3-9423-B1C900805F37"), CoClass(typeof(UpdateServiceManager))]
+ [ComImport, Guid("23857E3C-02BA-44A3-9423-B1C900805F37"), CoClass(typeof(UpdateServiceManagerClass))]
public interface IUpdateServiceManager
{
///
@@ -41,7 +41,7 @@ public static partial class WUApi
// serviceID, [in] BSTR authorizationCabPath, [out] IUpdateService **retval );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
[return: MarshalAs(UnmanagedType.Interface)]
- IUpdateService AddService([In, MarshalAs(UnmanagedType.BStr)] string serviceID, [In, MarshalAs(UnmanagedType.BStr)] string authorizationCabPath);
+ IUpdateService AddService([In, MarshalAs(UnmanagedType.BStr)] string serviceID, [In, MarshalAs(UnmanagedType.BStr)] string authorizationCabPath = "");
/// Registers a service with Automatic Updates.
/// An identifier for the service to be registered.
@@ -146,7 +146,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdateservicemanager2
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateServiceManager2")]
- [ComImport, Guid("0BB8531D-7E8D-424F-986C-A0B8F60A3E7B"), CoClass(typeof(UpdateServiceManager))]
+ [ComImport, Guid("0BB8531D-7E8D-424F-986C-A0B8F60A3E7B"), CoClass(typeof(UpdateServiceManagerClass))]
public interface IUpdateServiceManager2 : IUpdateServiceManager
{
///
@@ -177,7 +177,7 @@ public static partial class WUApi
// serviceID, [in] BSTR authorizationCabPath, [out] IUpdateService **retval );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743810)]
[return: MarshalAs(UnmanagedType.Interface)]
- new IUpdateService AddService([In, MarshalAs(UnmanagedType.BStr)] string serviceID, [In, MarshalAs(UnmanagedType.BStr)] string authorizationCabPath);
+ new IUpdateService AddService([In, MarshalAs(UnmanagedType.BStr)] string serviceID, [In, MarshalAs(UnmanagedType.BStr)] string authorizationCabPath = "");
/// Registers a service with Automatic Updates.
/// An identifier for the service to be registered.
@@ -382,12 +382,12 @@ public static partial class WUApi
///
///
///
- // https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateservicemanager2-addservice2 HRESULT AddService2( [in]
- // BSTR serviceID, [in] LONG flags, [in] BSTR authorizationCabPath, [out] IUpdateServiceRegistration **retval );
+ // https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdateservicemanager2-addservice2
+ // HRESULT AddService2( [in] BSTR serviceID, [in] LONG flags, [in] BSTR authorizationCabPath, [out] IUpdateServiceRegistration **retval );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610809347)]
[return: MarshalAs(UnmanagedType.Interface)]
- IUpdateServiceRegistration AddService2([In, MarshalAs(UnmanagedType.BStr)] string serviceID, [In] AddServiceFlag flags,
- [In, MarshalAs(UnmanagedType.BStr)] string authorizationCabPath);
+ IUpdateServiceRegistration AddService2([In, MarshalAs(UnmanagedType.BStr)] string serviceID,
+ [In] AddServiceFlag flags, [In, MarshalAs(UnmanagedType.BStr)] string authorizationCabPath);
}
/// Contains information about the registration state of a service.
@@ -470,7 +470,7 @@ public static partial class WUApi
/// to create the object.
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdatesession
- [ComImport, Guid("816858A4-260D-4260-933A-2585F1ABC76B"), CoClass(typeof(UpdateSession))]
+ [ComImport, Guid("816858A4-260D-4260-933A-2585F1ABC76B"), CoClass(typeof(UpdateSessionClass))]
public interface IUpdateSession
{
///
@@ -559,7 +559,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdatesession2
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateSession2")]
- [ComImport, Guid("91CAF7B0-EB23-49ED-9937-C52D817F46F7"), CoClass(typeof(UpdateSession))]
+ [ComImport, Guid("91CAF7B0-EB23-49ED-9937-C52D817F46F7"), CoClass(typeof(UpdateSessionClass))]
public interface IUpdateSession2 : IUpdateSession
{
///
@@ -679,7 +679,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iupdatesession3
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IUpdateSession3")]
- [ComImport, Guid("918EFD1E-B5D8-4C90-8540-AEB9BDC56F9D"), CoClass(typeof(UpdateSession))]
+ [ComImport, Guid("918EFD1E-B5D8-4C90-8540-AEB9BDC56F9D"), CoClass(typeof(UpdateSessionClass))]
public interface IUpdateSession3 : IUpdateSession2
{
///
@@ -868,7 +868,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iwebproxy
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IWebProxy")]
- [ComImport, Guid("174C81FE-AECD-4DAE-B8A0-2C6318DD86A8"), CoClass(typeof(WebProxy))]
+ [ComImport, Guid("174C81FE-AECD-4DAE-B8A0-2C6318DD86A8"), CoClass(typeof(WebProxyClass))]
public interface IWebProxy
{
///
@@ -1880,7 +1880,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-copyfromcache HRESULT CopyFromCache( [in] BSTR path,
// [in] VARIANT_BOOL toExtractCabFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743850)]
- new void CopyFromCache([In][MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
+ new void CopyFromCache([In, MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
///
/// Gets the suggested download priority of the update.
@@ -2882,7 +2882,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-copyfromcache HRESULT CopyFromCache( [in] BSTR path,
// [in] VARIANT_BOOL toExtractCabFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743850)]
- new void CopyFromCache([In][MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
+ new void CopyFromCache([In, MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
///
/// Gets the suggested download priority of the update.
@@ -3931,7 +3931,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-copyfromcache HRESULT CopyFromCache( [in] BSTR path,
// [in] VARIANT_BOOL toExtractCabFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743850)]
- new void CopyFromCache([In][MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
+ new void CopyFromCache([In, MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
///
/// Gets the suggested download priority of the update.
@@ -4993,7 +4993,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-copyfromcache HRESULT CopyFromCache( [in] BSTR path,
// [in] VARIANT_BOOL toExtractCabFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743850)]
- new void CopyFromCache([In][MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
+ new void CopyFromCache([In, MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
///
/// Gets the suggested download priority of the update.
@@ -6082,7 +6082,7 @@ public static partial class WUApi
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate-copyfromcache HRESULT CopyFromCache( [in] BSTR path,
// [in] VARIANT_BOOL toExtractCabFiles );
[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType = MethodCodeType.Runtime), DispId(1610743850)]
- new void CopyFromCache([In][MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
+ new void CopyFromCache([In, MarshalAs(UnmanagedType.BStr)] string path, [In] bool toExtractCabFiles);
///
/// Gets the suggested download priority of the update.
diff --git a/PInvoke/WUApi/WUApi5.cs b/PInvoke/WUApi/WUApi5.cs
index 974aaa79..4b6d8fd8 100644
--- a/PInvoke/WUApi/WUApi5.cs
+++ b/PInvoke/WUApi/WUApi5.cs
@@ -172,7 +172,7 @@ public static partial class WUApi
///
// https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nn-wuapi-iwindowsupdateagentinfo
[PInvokeData("wuapi.h", MSDNShortId = "NN:wuapi.IWindowsUpdateAgentInfo")]
- [ComImport, Guid("85713FA1-7796-4FA2-BE3B-E2D6124DD373"), CoClass(typeof(WindowsUpdateAgentInfo))]
+ [ComImport, Guid("85713FA1-7796-4FA2-BE3B-E2D6124DD373"), CoClass(typeof(WindowsUpdateAgentInfoClass))]
public interface IWindowsUpdateAgentInfo
{
/// Retrieves version information about Windows Update Agent (WUA).
@@ -222,71 +222,71 @@ public static partial class WUApi
/// CLSID_AutomaticUpdates
///
[ComImport, Guid("BFE18E9C-6D87-4450-B37C-E02F0B373803"), ClassInterface(ClassInterfaceType.None)]
- public class AutomaticUpdates { }
+ public class AutomaticUpdatesClass { }
///
/// CLSID_InstallationAgent
///
[ComImport, Guid("317E92FC-1679-46FD-A0B5-F08914DD8623"), ClassInterface(ClassInterfaceType.None)]
- public class InstallationAgent { }
+ public class InstallationAgentClass { }
///
/// CLSID_StringCollection
///
[ComImport, Guid("72C97D74-7C3B-40AE-B77D-ABDB22EBA6FB"), ClassInterface(ClassInterfaceType.None)]
- public class StringCollection { }
+ public class StringCollectionClass { }
///
/// CLSID_SystemInformation
///
[ComImport, Guid("C01B9BA0-BEA7-41BA-B604-D0A36F469133"), ClassInterface(ClassInterfaceType.None)]
- public class SystemInformation { }
+ public class SystemInformationClass { }
///
/// CLSID_UpdateCollection
///
[ComImport, Guid("13639463-00DB-4646-803D-528026140D88"), ClassInterface(ClassInterfaceType.None)]
- public class UpdateCollection { }
+ public class UpdateCollectionClass { }
///
/// CLSID_UpdateDownloader
///
[ComImport, Guid("5BAF654A-5A07-4264-A255-9FF54C7151E7"), ClassInterface(ClassInterfaceType.None)]
- public class UpdateDownloader { }
+ public class UpdateDownloaderClass { }
///
/// CLSID_UpdateInstaller
///
[ComImport, Guid("D2E0FE7F-D23E-48E1-93C0-6FA8CC346474"), ClassInterface(ClassInterfaceType.None)]
- public class UpdateInstaller { }
+ public class UpdateInstallerClass { }
///
/// CLSID_UpdateSearcher
///
[ComImport, Guid("B699E5E8-67FF-4177-88B0-3684A3388BFB"), ClassInterface(ClassInterfaceType.None)]
- public class UpdateSearcher { }
+ public class UpdateSearcherClass { }
///
/// CLSID_UpdateServiceManager
///
[ComImport, Guid("F8D253D9-89A4-4DAA-87B6-1168369F0B21"), ClassInterface(ClassInterfaceType.None)]
- public class UpdateServiceManager { }
+ public class UpdateServiceManagerClass { }
///
/// CLSID_UpdateSession
///
[ComImport, Guid("4CB43D7F-7EEE-4906-8698-60DA1C38F2FE"), ClassInterface(ClassInterfaceType.None)]
- public class UpdateSession { }
+ public class UpdateSessionClass { }
///
/// CLSID_WebProxy
///
[ComImport, Guid("650503CF-9108-4DDC-A2CE-6C2341E1C582"), ClassInterface(ClassInterfaceType.None)]
- public class WebProxy { }
+ public class WebProxyClass { }
///
/// CLSID_WindowsUpdateAgentInfo
///
[ComImport, Guid("C2E88C2F-6F5B-4AAA-894B-55C847AD3A2D"), ClassInterface(ClassInterfaceType.None)]
- public class WindowsUpdateAgentInfo { }
+ public class WindowsUpdateAgentInfoClass { }
}
\ No newline at end of file
diff --git a/PInvoke/WUApi/WUError.cs b/PInvoke/WUApi/WUError.cs
new file mode 100644
index 00000000..f2879fd3
--- /dev/null
+++ b/PInvoke/WUApi/WUError.cs
@@ -0,0 +1,1422 @@
+namespace Vanara.PInvoke;
+
+/// PInvoke API (methods, structures and constants) imported from Windows Update API.
+public static partial class WUApi
+{
+ static WUApi()
+ {
+ StaticFieldValueHash.AddFields(Lib_WUApi);
+ //ErrorHelper.AddErrorMessageLookupFunction();
+ }
+
+ ///
+ /// HRESULT error codes from wuerror.h. These are the same as the Windows Update error codes.
+ ///
+ [PInvokeData("wuerror.h")]
+ public enum WUError
+ {
+ /// Windows Update Agent was stopped successfully.
+ WU_S_SERVICE_STOP = 0x00240001,
+
+ /// Windows Update Agent updated itself.
+ WU_S_SELFUPDATE = 0x00240002,
+
+ /// Operation completed successfully but there were errors applying the updates.
+ WU_S_UPDATE_ERROR = 0x00240003,
+
+ /// A callback was marked to be disconnected later because the request to disconnect the operation came while a callback was executing.
+ WU_S_MARKED_FOR_DISCONNECT = 0x00240004,
+
+ /// The system must be restarted to complete installation of the update.
+ WU_S_REBOOT_REQUIRED = 0x00240005,
+
+ /// The update to be installed is already installed on the system.
+ WU_S_ALREADY_INSTALLED = 0x00240006,
+
+ /// The update to be removed is not installed on the system.
+ WU_S_ALREADY_UNINSTALLED = 0x00240007,
+
+ /// The update to be downloaded has already been downloaded.
+ WU_S_ALREADY_DOWNLOADED = 0x00240008,
+
+ /// The operation completed successfully, but some updates were skipped because the system is running on batteries.
+ WU_S_SOME_UPDATES_SKIPPED_ON_BATTERY = 0x00240009,
+
+ /// The update to be reverted is not present on the system.
+ WU_S_ALREADY_REVERTED = 0x0024000A,
+
+ /// The operation is skipped because the update service does not support the requested search criteria.
+ WU_S_SEARCH_CRITERIA_NOT_SUPPORTED = 0x00240010,
+
+ /// The installation operation for the update is still in progress.
+ WU_S_UH_INSTALLSTILLPENDING = 0x00242015,
+
+ /// The actual download size has been calculated by the handler.
+ WU_S_UH_DOWNLOAD_SIZE_CALCULATED = 0x00242016,
+
+ /// No operation was required by the server-initiated healing server response.
+ WU_S_SIH_NOOP = 0x00245001,
+
+ /// The update to be downloaded is already being downloaded.
+ WU_S_DM_ALREADYDOWNLOADING = 0x00246001,
+
+ /// Metadata verification was skipped by enforcement mode.
+ WU_S_METADATA_SKIPPED_BY_ENFORCEMENTMODE = 0x00247101,
+
+ /// A server configuration refresh resulted in metadata signature verification to be ignored.
+ WU_S_METADATA_IGNORED_SIGNATURE_VERIFICATION = 0x00247102,
+
+ /// Search operation completed successfully but one or more services were shedding load.
+ WU_S_SEARCH_LOAD_SHEDDING = 0x00248001,
+
+ /// There was no need to retrieve an AAD device ticket.
+ WU_S_AAD_DEVICE_TICKET_NOT_NEEDED = 0x00248002,
+
+ /// Windows Update Agent was unable to provide the service.
+ WU_E_NO_SERVICE = unchecked((int)0x80240001),
+
+ /// The maximum capacity of the service was exceeded.
+ WU_E_MAX_CAPACITY_REACHED = unchecked((int)0x80240002),
+
+ /// An ID cannot be found.
+ WU_E_UNKNOWN_ID = unchecked((int)0x80240003),
+
+ /// The object could not be initialized.
+ WU_E_NOT_INITIALIZED = unchecked((int)0x80240004),
+
+ /// The update handler requested a byte range overlapping a previously requested range.
+ WU_E_RANGEOVERLAP = unchecked((int)0x80240005),
+
+ /// The requested number of byte ranges exceeds the maximum number (2^31 - 1).
+ WU_E_TOOMANYRANGES = unchecked((int)0x80240006),
+
+ /// The index to a collection was invalid.
+ WU_E_INVALIDINDEX = unchecked((int)0x80240007),
+
+ /// The key for the item queried could not be found.
+ WU_E_ITEMNOTFOUND = unchecked((int)0x80240008),
+
+ /// Another conflicting operation was in progress. Some operations such as installation cannot be performed twice simultaneously.
+ WU_E_OPERATIONINPROGRESS = unchecked((int)0x80240009),
+
+ /// Cancellation of the operation was not allowed.
+ WU_E_COULDNOTCANCEL = unchecked((int)0x8024000A),
+
+ /// Operation was cancelled.
+ WU_E_CALL_CANCELLED = unchecked((int)0x8024000B),
+
+ /// No operation was required.
+ WU_E_NOOP = unchecked((int)0x8024000C),
+
+ /// Windows Update Agent could not find required information in the update's XML data.
+ WU_E_XML_MISSINGDATA = unchecked((int)0x8024000D),
+
+ /// Windows Update Agent found invalid information in the update's XML data.
+ WU_E_XML_INVALID = unchecked((int)0x8024000E),
+
+ /// Circular update relationships were detected in the metadata.
+ WU_E_CYCLE_DETECTED = unchecked((int)0x8024000F),
+
+ /// Update relationships too deep to evaluate were evaluated.
+ WU_E_TOO_DEEP_RELATION = unchecked((int)0x80240010),
+
+ /// An invalid update relationship was detected.
+ WU_E_INVALID_RELATIONSHIP = unchecked((int)0x80240011),
+
+ /// An invalid registry value was read.
+ WU_E_REG_VALUE_INVALID = unchecked((int)0x80240012),
+
+ /// Operation tried to add a duplicate item to a list.
+ WU_E_DUPLICATE_ITEM = unchecked((int)0x80240013),
+
+ /// Updates requested for install are not installable by caller.
+ WU_E_INVALID_INSTALL_REQUESTED = unchecked((int)0x80240014),
+
+ /// Operation tried to install while another installation was in progress or the system was pending a mandatory restart.
+ WU_E_INSTALL_NOT_ALLOWED = unchecked((int)0x80240016),
+
+ /// Operation was not performed because there are no applicable updates.
+ WU_E_NOT_APPLICABLE = unchecked((int)0x80240017),
+
+ /// Operation failed because a required user token is missing.
+ WU_E_NO_USERTOKEN = unchecked((int)0x80240018),
+
+ /// An exclusive update cannot be installed with other updates at the same time.
+ WU_E_EXCLUSIVE_INSTALL_CONFLICT = unchecked((int)0x80240019),
+
+ /// A policy value was not set.
+ WU_E_POLICY_NOT_SET = unchecked((int)0x8024001A),
+
+ /// The operation could not be performed because the Windows Update Agent is self-updating.
+ WU_E_SELFUPDATE_IN_PROGRESS = unchecked((int)0x8024001B),
+
+ /// An update contains invalid metadata.
+ WU_E_INVALID_UPDATE = unchecked((int)0x8024001D),
+
+ /// Operation did not complete because the service or system was being shut down.
+ WU_E_SERVICE_STOP = unchecked((int)0x8024001E),
+
+ /// Operation did not complete because the network connection was unavailable.
+ WU_E_NO_CONNECTION = unchecked((int)0x8024001F),
+
+ /// Operation did not complete because there is no logged-on interactive user.
+ WU_E_NO_INTERACTIVE_USER = unchecked((int)0x80240020),
+
+ /// Operation did not complete because it timed out.
+ WU_E_TIME_OUT = unchecked((int)0x80240021),
+
+ /// Operation failed for all the updates.
+ WU_E_ALL_UPDATES_FAILED = unchecked((int)0x80240022),
+
+ /// The license terms for all updates were declined.
+ WU_E_EULAS_DECLINED = unchecked((int)0x80240023),
+
+ /// There are no updates.
+ WU_E_NO_UPDATE = unchecked((int)0x80240024),
+
+ /// Group Policy settings prevented access to Windows Update.
+ WU_E_USER_ACCESS_DISABLED = unchecked((int)0x80240025),
+
+ /// The type of update is invalid.
+ WU_E_INVALID_UPDATE_TYPE = unchecked((int)0x80240026),
+
+ /// The URL exceeded the maximum length.
+ WU_E_URL_TOO_LONG = unchecked((int)0x80240027),
+
+ /// The update could not be uninstalled because the request did not originate from a WSUS server.
+ WU_E_UNINSTALL_NOT_ALLOWED = unchecked((int)0x80240028),
+
+ /// Search may have missed some updates before there is an unlicensed application on the system.
+ WU_E_INVALID_PRODUCT_LICENSE = unchecked((int)0x80240029),
+
+ /// A component required to detect applicable updates was missing.
+ WU_E_MISSING_HANDLER = unchecked((int)0x8024002A),
+
+ /// An operation did not complete because it requires a newer version of server.
+ WU_E_LEGACYSERVER = unchecked((int)0x8024002B),
+
+ /// A delta-compressed update could not be installed because it required the source.
+ WU_E_BIN_SOURCE_ABSENT = unchecked((int)0x8024002C),
+
+ /// A full-file update could not be installed because it required the source.
+ WU_E_SOURCE_ABSENT = unchecked((int)0x8024002D),
+
+ /// Access to an unmanaged server is not allowed.
+ WU_E_WU_DISABLED = unchecked((int)0x8024002E),
+
+ /// Operation did not complete because the DisableWindowsUpdateAccess policy was set.
+ WU_E_CALL_CANCELLED_BY_POLICY = unchecked((int)0x8024002F),
+
+ /// The format of the proxy list was invalid.
+ WU_E_INVALID_PROXY_SERVER = unchecked((int)0x80240030),
+
+ /// The file is in the wrong format.
+ WU_E_INVALID_FILE = unchecked((int)0x80240031),
+
+ /// The search criteria string was invalid.
+ WU_E_INVALID_CRITERIA = unchecked((int)0x80240032),
+
+ /// License terms could not be downloaded.
+ WU_E_EULA_UNAVAILABLE = unchecked((int)0x80240033),
+
+ /// Update failed to download.
+ WU_E_DOWNLOAD_FAILED = unchecked((int)0x80240034),
+
+ /// The update was not processed.
+ WU_E_UPDATE_NOT_PROCESSED = unchecked((int)0x80240035),
+
+ /// The object's current state did not allow the operation.
+ WU_E_INVALID_OPERATION = unchecked((int)0x80240036),
+
+ /// The functionality for the operation is not supported.
+ WU_E_NOT_SUPPORTED = unchecked((int)0x80240037),
+
+ /// The downloaded file has an unexpected content type.
+ WU_E_WINHTTP_INVALID_FILE = unchecked((int)0x80240038),
+
+ /// Agent is asked by server to resync too many times.
+ WU_E_TOO_MANY_RESYNC = unchecked((int)0x80240039),
+
+ /// WUA API method does not run on Server Core installation.
+ WU_E_NO_SERVER_CORE_SUPPORT = unchecked((int)0x80240040),
+
+ /// Service is not available while sysprep is running.
+ WU_E_SYSPREP_IN_PROGRESS = unchecked((int)0x80240041),
+
+ /// The update service is no longer registered with AU.
+ WU_E_UNKNOWN_SERVICE = unchecked((int)0x80240042),
+
+ /// There is no support for WUA UI.
+ WU_E_NO_UI_SUPPORT = unchecked((int)0x80240043),
+
+ /// Only administrators can perform this operation on per-machine updates.
+ WU_E_PER_MACHINE_UPDATE_ACCESS_DENIED = unchecked((int)0x80240044),
+
+ /// A search was attempted with a scope that is not currently supported for this type of search.
+ WU_E_UNSUPPORTED_SEARCHSCOPE = unchecked((int)0x80240045),
+
+ /// The URL does not point to a file.
+ WU_E_BAD_FILE_URL = unchecked((int)0x80240046),
+
+ /// The update could not be reverted.
+ WU_E_REVERT_NOT_ALLOWED = unchecked((int)0x80240047),
+
+ /// The featured update notification info returned by the server is invalid.
+ WU_E_INVALID_NOTIFICATION_INFO = unchecked((int)0x80240048),
+
+ /// The data is out of range.
+ WU_E_OUTOFRANGE = unchecked((int)0x80240049),
+
+ /// Windows Update agent operations are not available while OS setup is running.
+ WU_E_SETUP_IN_PROGRESS = unchecked((int)0x8024004A),
+
+ /// An orphaned downloadjob was found with no active callers.
+ WU_E_ORPHANED_DOWNLOAD_JOB = unchecked((int)0x8024004B),
+
+ /// An update could not be installed because the system battery power level is too low.
+ WU_E_LOW_BATTERY = unchecked((int)0x8024004C),
+
+ /// The downloaded infrastructure file is incorrectly formatted.
+ WU_E_INFRASTRUCTUREFILE_INVALID_FORMAT = unchecked((int)0x8024004D),
+
+ /// The infrastructure file must be downloaded using strong SSL.
+ WU_E_INFRASTRUCTUREFILE_REQUIRES_SSL = unchecked((int)0x8024004E),
+
+ /// A discovery call contributed to a non-zero operation count at idle timer shutdown.
+ WU_E_IDLESHUTDOWN_OPCOUNT_DISCOVERY = unchecked((int)0x8024004F),
+
+ /// A search call contributed to a non-zero operation count at idle timer shutdown.
+ WU_E_IDLESHUTDOWN_OPCOUNT_SEARCH = unchecked((int)0x80240050),
+
+ /// A download call contributed to a non-zero operation count at idle timer shutdown.
+ WU_E_IDLESHUTDOWN_OPCOUNT_DOWNLOAD = unchecked((int)0x80240051),
+
+ /// An install call contributed to a non-zero operation count at idle timer shutdown.
+ WU_E_IDLESHUTDOWN_OPCOUNT_INSTALL = unchecked((int)0x80240052),
+
+ /// An unspecified call contributed to a non-zero operation count at idle timer shutdown.
+ WU_E_IDLESHUTDOWN_OPCOUNT_OTHER = unchecked((int)0x80240053),
+
+ /// An interactive user cancelled this operation, which was started from the Windows Update Agent UI.
+ WU_E_INTERACTIVE_CALL_CANCELLED = unchecked((int)0x80240054),
+
+ /// Automatic Updates cancelled this operation because it applies to an update that is no longer applicable to this computer.
+ WU_E_AU_CALL_CANCELLED = unchecked((int)0x80240055),
+
+ /// This version or edition of the operating system doesn't support the needed functionality.
+ WU_E_SYSTEM_UNSUPPORTED = unchecked((int)0x80240056),
+
+ /// The requested update download or install handler, or update applicability expression evaluator, is not provided by this Agent plugin.
+ WU_E_NO_SUCH_HANDLER_PLUGIN = unchecked((int)0x80240057),
+
+ /// The requested serialization version is not supported.
+ WU_E_INVALID_SERIALIZATION_VERSION = unchecked((int)0x80240058),
+
+ /// The current network cost does not meet the conditions set by the network cost policy.
+ WU_E_NETWORK_COST_EXCEEDS_POLICY = unchecked((int)0x80240059),
+
+ /// The call is cancelled because it applies to an update that is hidden (no longer applicable to this computer).
+ WU_E_CALL_CANCELLED_BY_HIDE = unchecked((int)0x8024005A),
+
+ /// The call is cancelled because it applies to an update that is invalid (no longer applicable to this computer).
+ WU_E_CALL_CANCELLED_BY_INVALID = unchecked((int)0x8024005B),
+
+ /// The specified volume id is invalid.
+ WU_E_INVALID_VOLUMEID = unchecked((int)0x8024005C),
+
+ /// The specified volume id is unrecognized by the system.
+ WU_E_UNRECOGNIZED_VOLUMEID = unchecked((int)0x8024005D),
+
+ /// The installation extended error code is not specified.
+ WU_E_EXTENDEDERROR_NOTSET = unchecked((int)0x8024005E),
+
+ /// The installation extended error code is set to general fail.
+ WU_E_EXTENDEDERROR_FAILED = unchecked((int)0x8024005F),
+
+ /// A service registration call contributed to a non-zero operation count at idle timer shutdown.
+ WU_E_IDLESHUTDOWN_OPCOUNT_SERVICEREGISTRATION = unchecked((int)0x80240060),
+
+ /// Signature validation of the file fails to find valid SHA2+ signature on MS signed payload.
+ WU_E_FILETRUST_SHA2SIGNATURE_MISSING = unchecked((int)0x80240061),
+
+ /// The update is not in the servicing approval list.
+ WU_E_UPDATE_NOT_APPROVED = unchecked((int)0x80240062),
+
+ /// The search call was cancelled by another interactive search against the same service.
+ WU_E_CALL_CANCELLED_BY_INTERACTIVE_SEARCH = unchecked((int)0x80240063),
+
+ /// Resume of install job not allowed due to another installation in progress.
+ WU_E_INSTALL_JOB_RESUME_NOT_ALLOWED = unchecked((int)0x80240064),
+
+ /// Resume of install job not allowed because job is not suspended.
+ WU_E_INSTALL_JOB_NOT_SUSPENDED = unchecked((int)0x80240065),
+
+ /// User context passed to installation from caller with insufficient privileges.
+ WU_E_INSTALL_USERCONTEXT_ACCESSDENIED = unchecked((int)0x80240066),
+
+ /// An operation failed due to reasons not covered by another error code.
+ WU_E_UNEXPECTED = unchecked((int)0x80240FFF),
+
+ /// Search may have missed some updates because the Windows Installer is less than version 3.1.
+ WU_E_MSI_WRONG_VERSION = unchecked((int)0x80241001),
+
+ /// Search may have missed some updates because the Windows Installer is not configured.
+ WU_E_MSI_NOT_CONFIGURED = unchecked((int)0x80241002),
+
+ /// Search may have missed some updates because policy has disabled Windows Installer patching.
+ WU_E_MSP_DISABLED = unchecked((int)0x80241003),
+
+ /// An update could not be applied because the application is installed per-user.
+ WU_E_MSI_WRONG_APP_CONTEXT = unchecked((int)0x80241004),
+
+ /// Search may have missed some updates because the Windows Installer is less than version 3.1.
+ WU_E_MSI_NOT_PRESENT = unchecked((int)0x80241005),
+
+ /// Search may have missed some updates because there was a failure of the Windows Installer.
+ WU_E_MSP_UNEXPECTED = unchecked((int)0x80241FFF),
+
+ /// WU_E_PT_SOAPCLIENT_* error codes map to the SOAPCLIENT_ERROR enum of the ATL Server Library.
+ WU_E_PT_SOAPCLIENT_BASE = unchecked((int)0x80244000),
+
+ /// Same as SOAPCLIENT_INITIALIZE_ERROR - initialization of the SOAP client failed, possibly because of an MSXML installation failure.
+ WU_E_PT_SOAPCLIENT_INITIALIZE = unchecked((int)0x80244001),
+
+ /// Same as SOAPCLIENT_OUTOFMEMORY - SOAP client failed because it ran out of memory.
+ WU_E_PT_SOAPCLIENT_OUTOFMEMORY = unchecked((int)0x80244002),
+
+ /// Same as SOAPCLIENT_GENERATE_ERROR - SOAP client failed to generate the request.
+ WU_E_PT_SOAPCLIENT_GENERATE = unchecked((int)0x80244003),
+
+ /// Same as SOAPCLIENT_CONNECT_ERROR - SOAP client failed to connect to the server.
+ WU_E_PT_SOAPCLIENT_CONNECT = unchecked((int)0x80244004),
+
+ /// Same as SOAPCLIENT_SEND_ERROR - SOAP client failed to send a message for reasons of WU_E_WINHTTP_* error codes.
+ WU_E_PT_SOAPCLIENT_SEND = unchecked((int)0x80244005),
+
+ /// Same as SOAPCLIENT_SERVER_ERROR - SOAP client failed because there was a server error.
+ WU_E_PT_SOAPCLIENT_SERVER = unchecked((int)0x80244006),
+
+ /// Same as SOAPCLIENT_SOAPFAULT - SOAP client failed because there was a SOAP fault for reasons of WU_E_PT_SOAP_* error codes.
+ WU_E_PT_SOAPCLIENT_SOAPFAULT = unchecked((int)0x80244007),
+
+ /// Same as SOAPCLIENT_PARSEFAULT_ERROR - SOAP client failed to parse a SOAP fault.
+ WU_E_PT_SOAPCLIENT_PARSEFAULT = unchecked((int)0x80244008),
+
+ /// Same as SOAPCLIENT_READ_ERROR - SOAP client failed while reading the response from the server.
+ WU_E_PT_SOAPCLIENT_READ = unchecked((int)0x80244009),
+
+ /// Same as SOAPCLIENT_PARSE_ERROR - SOAP client failed to parse the response from the server.
+ WU_E_PT_SOAPCLIENT_PARSE = unchecked((int)0x8024400A),
+
+ /// Same as SOAP_E_VERSION_MISMATCH - SOAP client found an unrecognizable namespace for the SOAP envelope.
+ WU_E_PT_SOAP_VERSION = unchecked((int)0x8024400B),
+
+ /// Same as SOAP_E_MUST_UNDERSTAND - SOAP client was unable to understand a header.
+ WU_E_PT_SOAP_MUST_UNDERSTAND = unchecked((int)0x8024400C),
+
+ /// Same as SOAP_E_CLIENT - SOAP client found the message was malformed; fix before resending.
+ WU_E_PT_SOAP_CLIENT = unchecked((int)0x8024400D),
+
+ /// Same as SOAP_E_SERVER - The SOAP message could not be processed due to a server error; resend later.
+ WU_E_PT_SOAP_SERVER = unchecked((int)0x8024400E),
+
+ /// There was an unspecified Windows Management Instrumentation (WMI) error.
+ WU_E_PT_WMI_ERROR = unchecked((int)0x8024400F),
+
+ /// The number of round trips to the server exceeded the maximum limit.
+ WU_E_PT_EXCEEDED_MAX_SERVER_TRIPS = unchecked((int)0x80244010),
+
+ /// WUServer policy value is missing in the registry.
+ WU_E_PT_SUS_SERVER_NOT_SET = unchecked((int)0x80244011),
+
+ /// Initialization failed because the object was already initialized.
+ WU_E_PT_DOUBLE_INITIALIZATION = unchecked((int)0x80244012),
+
+ /// The computer name could not be determined.
+ WU_E_PT_INVALID_COMPUTER_NAME = unchecked((int)0x80244013),
+
+ /// The reply from the server indicates that the server was changed or the cookie was invalid; refresh the state of the internal cache and retry.
+ WU_E_PT_REFRESH_CACHE_REQUIRED = unchecked((int)0x80244015),
+
+ /// Same as HTTP status 400 - the server could not process the request due to invalid syntax.
+ WU_E_PT_HTTP_STATUS_BAD_REQUEST = unchecked((int)0x80244016),
+
+ /// Same as HTTP status 401 - the requested resource requires user authentication.
+ WU_E_PT_HTTP_STATUS_DENIED = unchecked((int)0x80244017),
+
+ /// Same as HTTP status 403 - server understood the request, but declined to fulfill it.
+ WU_E_PT_HTTP_STATUS_FORBIDDEN = unchecked((int)0x80244018),
+
+ /// Same as HTTP status 404 - the server cannot find the requested URI (Uniform Resource Identifier).
+ WU_E_PT_HTTP_STATUS_NOT_FOUND = unchecked((int)0x80244019),
+
+ /// Same as HTTP status 405 - the HTTP method is not allowed.
+ WU_E_PT_HTTP_STATUS_BAD_METHOD = unchecked((int)0x8024401A),
+
+ /// Same as HTTP status 407 - proxy authentication is required.
+ WU_E_PT_HTTP_STATUS_PROXY_AUTH_REQ = unchecked((int)0x8024401B),
+
+ /// Same as HTTP status 408 - the server timed out waiting for the request.
+ WU_E_PT_HTTP_STATUS_REQUEST_TIMEOUT = unchecked((int)0x8024401C),
+
+ /// Same as HTTP status 409 - the request was not completed due to a conflict with the current state of the resource.
+ WU_E_PT_HTTP_STATUS_CONFLICT = unchecked((int)0x8024401D),
+
+ /// Same as HTTP status 410 - requested resource is no longer available at the server.
+ WU_E_PT_HTTP_STATUS_GONE = unchecked((int)0x8024401E),
+
+ /// Same as HTTP status 500 - an error internal to the server prevented fulfilling the request.
+ WU_E_PT_HTTP_STATUS_SERVER_ERROR = unchecked((int)0x8024401F),
+
+ /// Same as HTTP status 500 - server does not support the functionality required to fulfill the request.
+ WU_E_PT_HTTP_STATUS_NOT_SUPPORTED = unchecked((int)0x80244020),
+
+ /// Same as HTTP status 502 - the server, while acting as a gateway or proxy, received an invalid response from the upstream server it accessed in attempting to fulfill the request.
+ WU_E_PT_HTTP_STATUS_BAD_GATEWAY = unchecked((int)0x80244021),
+
+ /// Same as HTTP status 503 - the service is temporarily overloaded.
+ WU_E_PT_HTTP_STATUS_SERVICE_UNAVAIL = unchecked((int)0x80244022),
+
+ /// Same as HTTP status 503 - the request was timed out waiting for a gateway.
+ WU_E_PT_HTTP_STATUS_GATEWAY_TIMEOUT = unchecked((int)0x80244023),
+
+ /// Same as HTTP status 505 - the server does not support the HTTP protocol version used for the request.
+ WU_E_PT_HTTP_STATUS_VERSION_NOT_SUP = unchecked((int)0x80244024),
+
+ /// Operation failed due to a changed file location; refresh internal state and resend.
+ WU_E_PT_FILE_LOCATIONS_CHANGED = unchecked((int)0x80244025),
+
+ /// Operation failed because Windows Update Agent does not support registration with a non-WSUS server.
+ WU_E_PT_REGISTRATION_NOT_SUPPORTED = unchecked((int)0x80244026),
+
+ /// The server returned an empty authentication information list.
+ WU_E_PT_NO_AUTH_PLUGINS_REQUESTED = unchecked((int)0x80244027),
+
+ /// Windows Update Agent was unable to create any valid authentication cookies.
+ WU_E_PT_NO_AUTH_COOKIES_CREATED = unchecked((int)0x80244028),
+
+ /// A configuration property value was wrong.
+ WU_E_PT_INVALID_CONFIG_PROP = unchecked((int)0x80244029),
+
+ /// A configuration property value was missing.
+ WU_E_PT_CONFIG_PROP_MISSING = unchecked((int)0x8024402A),
+
+ /// The HTTP request could not be completed and the reason did not correspond to any of the WU_E_PT_HTTP_* error codes.
+ WU_E_PT_HTTP_STATUS_NOT_MAPPED = unchecked((int)0x8024402B),
+
+ /// Same as ERROR_WINHTTP_NAME_NOT_RESOLVED - the proxy server or target server name cannot be resolved.
+ WU_E_PT_WINHTTP_NAME_NOT_RESOLVED = unchecked((int)0x8024402C),
+
+ /// The server is shedding load.
+ WU_E_PT_LOAD_SHEDDING = unchecked((int)0x8024402D),
+
+ /// Windows Update Agent failed to download a redirector cabinet file with a new redirectorId value from the server during the recovery.
+ WU_E_PT_SAME_REDIR_ID = unchecked((int)0x8024502D),
+
+ /// A redirector recovery action did not complete because the server is managed.
+ WU_E_PT_NO_MANAGED_RECOVER = unchecked((int)0x8024502E),
+
+ /// External cab file processing completed with some errors.
+ WU_E_PT_ECP_SUCCEEDED_WITH_ERRORS = unchecked((int)0x8024402F),
+
+ /// The external cab processor initialization did not complete.
+ WU_E_PT_ECP_INIT_FAILED = unchecked((int)0x80244030),
+
+ /// The format of a metadata file was invalid.
+ WU_E_PT_ECP_INVALID_FILE_FORMAT = unchecked((int)0x80244031),
+
+ /// External cab processor found invalid metadata.
+ WU_E_PT_ECP_INVALID_METADATA = unchecked((int)0x80244032),
+
+ /// The file digest could not be extracted from an external cab file.
+ WU_E_PT_ECP_FAILURE_TO_EXTRACT_DIGEST = unchecked((int)0x80244033),
+
+ /// An external cab file could not be decompressed.
+ WU_E_PT_ECP_FAILURE_TO_DECOMPRESS_CAB_FILE = unchecked((int)0x80244034),
+
+ /// External cab processor was unable to get file locations.
+ WU_E_PT_ECP_FILE_LOCATION_ERROR = unchecked((int)0x80244035),
+
+ /// The server does not support category-specific search; Full catalog search has to be issued instead.
+ WU_E_PT_CATALOG_SYNC_REQUIRED = unchecked((int)0x80240436),
+
+ /// There was a problem authorizing with the service.
+ WU_E_PT_SECURITY_VERIFICATION_FAILURE = unchecked((int)0x80240437),
+
+ /// There is no route or network connectivity to the endpoint.
+ WU_E_PT_ENDPOINT_UNREACHABLE = unchecked((int)0x80240438),
+
+ /// The data received does not meet the data contract expectations.
+ WU_E_PT_INVALID_FORMAT = unchecked((int)0x80240439),
+
+ /// The url is invalid.
+ WU_E_PT_INVALID_URL = unchecked((int)0x8024043A),
+
+ /// Unable to load NWS runtime.
+ WU_E_PT_NWS_NOT_LOADED = unchecked((int)0x8024043B),
+
+ /// The proxy auth scheme is not supported.
+ WU_E_PT_PROXY_AUTH_SCHEME_NOT_SUPPORTED = unchecked((int)0x8024043C),
+
+ /// The requested service property is not available.
+ WU_E_SERVICEPROP_NOTAVAIL = unchecked((int)0x8024043D),
+
+ /// The endpoint provider plugin requires online refresh.
+ WU_E_PT_ENDPOINT_REFRESH_REQUIRED = unchecked((int)0x8024043E),
+
+ /// A URL for the requested service endpoint is not available.
+ WU_E_PT_ENDPOINTURL_NOTAVAIL = unchecked((int)0x8024043F),
+
+ /// The connection to the service endpoint died.
+ WU_E_PT_ENDPOINT_DISCONNECTED = unchecked((int)0x80240440),
+
+ /// The operation is invalid because protocol talker is in an inappropriate state.
+ WU_E_PT_INVALID_OPERATION = unchecked((int)0x80240441),
+
+ /// The object is in a faulted state due to a previous error.
+ WU_E_PT_OBJECT_FAULTED = unchecked((int)0x80240442),
+
+ /// The operation would lead to numeric overflow.
+ WU_E_PT_NUMERIC_OVERFLOW = unchecked((int)0x80240443),
+
+ /// The operation was aborted.
+ WU_E_PT_OPERATION_ABORTED = unchecked((int)0x80240444),
+
+ /// The operation was abandoned.
+ WU_E_PT_OPERATION_ABANDONED = unchecked((int)0x80240445),
+
+ /// A quota was exceeded.
+ WU_E_PT_QUOTA_EXCEEDED = unchecked((int)0x80240446),
+
+ /// The information was not available in the specified language.
+ WU_E_PT_NO_TRANSLATION_AVAILABLE = unchecked((int)0x80240447),
+
+ /// The address is already being used.
+ WU_E_PT_ADDRESS_IN_USE = unchecked((int)0x80240448),
+
+ /// The address is not valid for this context.
+ WU_E_PT_ADDRESS_NOT_AVAILABLE = unchecked((int)0x80240449),
+
+ /// Unrecognized error occurred in the Windows Web Services framework.
+ WU_E_PT_OTHER = unchecked((int)0x8024044A),
+
+ /// A security operation failed in the Windows Web Services framework.
+ WU_E_PT_SECURITY_SYSTEM_FAILURE = unchecked((int)0x8024044B),
+
+ /// The client is data boundary restricted and needs to talk to a restricted endpoint.
+ WU_E_PT_DATA_BOUNDARY_RESTRICTED = unchecked((int)0x80244100),
+
+ /// The client hit an error in retrievingg AAD device ticket.
+ WU_E_PT_GENERAL_AAD_CLIENT_ERROR = unchecked((int)0x80244101),
+
+ /// A communication error not covered by another WU_E_PT_* error code.
+ WU_E_PT_UNEXPECTED = unchecked((int)0x80244FFF),
+
+ /// The redirector XML document could not be loaded into the DOM class.
+ WU_E_REDIRECTOR_LOAD_XML = unchecked((int)0x80245001),
+
+ /// The redirector XML document is missing some required information.
+ WU_E_REDIRECTOR_S_FALSE = unchecked((int)0x80245002),
+
+ /// The redirectorId in the downloaded redirector cab is less than in the cached cab.
+ WU_E_REDIRECTOR_ID_SMALLER = unchecked((int)0x80245003),
+
+ /// The service ID is not supported in the service environment.
+ WU_E_REDIRECTOR_UNKNOWN_SERVICE = unchecked((int)0x80245004),
+
+ /// The response from the redirector server had an unsupported content type.
+ WU_E_REDIRECTOR_UNSUPPORTED_CONTENTTYPE = unchecked((int)0x80245005),
+
+ /// The response from the redirector server had an error status or was invalid.
+ WU_E_REDIRECTOR_INVALID_RESPONSE = unchecked((int)0x80245006),
+
+ /// The maximum number of name value pairs was exceeded by the attribute provider.
+ WU_E_REDIRECTOR_ATTRPROVIDER_EXCEEDED_MAX_NAMEVALUE = unchecked((int)0x80245008),
+
+ /// The name received from the attribute provider was invalid.
+ WU_E_REDIRECTOR_ATTRPROVIDER_INVALID_NAME = unchecked((int)0x80245009),
+
+ /// The value received from the attribute provider was invalid.
+ WU_E_REDIRECTOR_ATTRPROVIDER_INVALID_VALUE = unchecked((int)0x8024500A),
+
+ /// There was an error in connecting to or parsing the response from the Service Locator Service redirector server.
+ WU_E_REDIRECTOR_SLS_GENERIC_ERROR = unchecked((int)0x8024500B),
+
+ /// Connections to the redirector server are disallowed by managed policy.
+ WU_E_REDIRECTOR_CONNECT_POLICY = unchecked((int)0x8024500C),
+
+ /// The redirector would go online but is disallowed by caller configuration.
+ WU_E_REDIRECTOR_ONLINE_DISALLOWED = unchecked((int)0x8024500D),
+
+ /// The redirector failed for reasons not covered by another WU_E_REDIRECTOR_* error code.
+ WU_E_REDIRECTOR_UNEXPECTED = unchecked((int)0x802450FF),
+
+ /// Verification of the servicing engine package failed.
+ WU_E_SIH_VERIFY_DOWNLOAD_ENGINE = unchecked((int)0x80245101),
+
+ /// Verification of a servicing package failed.
+ WU_E_SIH_VERIFY_DOWNLOAD_PAYLOAD = unchecked((int)0x80245102),
+
+ /// Verification of the staged engine failed.
+ WU_E_SIH_VERIFY_STAGE_ENGINE = unchecked((int)0x80245103),
+
+ /// Verification of a staged payload failed.
+ WU_E_SIH_VERIFY_STAGE_PAYLOAD = unchecked((int)0x80245104),
+
+ /// An internal error occurred where the servicing action was not found.
+ WU_E_SIH_ACTION_NOT_FOUND = unchecked((int)0x80245105),
+
+ /// There was a parse error in the service environment response.
+ WU_E_SIH_SLS_PARSE = unchecked((int)0x80245106),
+
+ /// A downloaded file failed an integrity check.
+ WU_E_SIH_INVALIDHASH = unchecked((int)0x80245107),
+
+ /// No engine was provided by the server-initiated healing server response.
+ WU_E_SIH_NO_ENGINE = unchecked((int)0x80245108),
+
+ /// Post-reboot install failed.
+ WU_E_SIH_POST_REBOOT_INSTALL_FAILED = unchecked((int)0x80245109),
+
+ /// There were pending reboot actions, but cached SLS response was not found post-reboot.
+ WU_E_SIH_POST_REBOOT_NO_CACHED_SLS_RESPONSE = unchecked((int)0x8024510A),
+
+ /// Parsing command line arguments failed.
+ WU_E_SIH_PARSE = unchecked((int)0x8024510B),
+
+ /// Security check failed.
+ WU_E_SIH_SECURITY = unchecked((int)0x8024510C),
+
+ /// PPL check failed.
+ WU_E_SIH_PPL = unchecked((int)0x8024510D),
+
+ /// Execution was disabled by policy.
+ WU_E_SIH_POLICY = unchecked((int)0x8024510E),
+
+ /// A standard exception was caught.
+ WU_E_SIH_STDEXCEPTION = unchecked((int)0x8024510F),
+
+ /// A non-standard exception was caught.
+ WU_E_SIH_NONSTDEXCEPTION = unchecked((int)0x80245110),
+
+ /// The server-initiated healing engine encountered an exception not covered by another WU_E_SIH_* error code.
+ WU_E_SIH_ENGINE_EXCEPTION = unchecked((int)0x80245111),
+
+ /// You are running SIH Client with cmd not supported on your platform.
+ WU_E_SIH_BLOCKED_FOR_PLATFORM = unchecked((int)0x80245112),
+
+ /// Another SIH Client is already running.
+ WU_E_SIH_ANOTHER_INSTANCE_RUNNING = unchecked((int)0x80245113),
+
+ /// Disable DNS resiliency feature per service configuration.
+ WU_E_SIH_DNSRESILIENCY_OFF = unchecked((int)0x80245114),
+
+ /// There was a failure for reasons not covered by another WU_E_SIH_* error code.
+ WU_E_SIH_UNEXPECTED = unchecked((int)0x802451FF),
+
+ /// A driver was skipped.
+ WU_E_DRV_PRUNED = unchecked((int)0x8024C001),
+
+ /// A property for the driver could not be found. It may not conform with required specifications.
+ WU_E_DRV_NOPROP_OR_LEGACY = unchecked((int)0x8024C002),
+
+ /// The registry type read for the driver does not match the expected type.
+ WU_E_DRV_REG_MISMATCH = unchecked((int)0x8024C003),
+
+ /// The driver update is missing metadata.
+ WU_E_DRV_NO_METADATA = unchecked((int)0x8024C004),
+
+ /// The driver update is missing a required attribute.
+ WU_E_DRV_MISSING_ATTRIBUTE = unchecked((int)0x8024C005),
+
+ /// Driver synchronization failed.
+ WU_E_DRV_SYNC_FAILED = unchecked((int)0x8024C006),
+
+ /// Information required for the synchronization of applicable printers is missing.
+ WU_E_DRV_NO_PRINTER_CONTENT = unchecked((int)0x8024C007),
+
+ /// After installing a driver update, the updated device has reported a problem.
+ WU_E_DRV_DEVICE_PROBLEM = unchecked((int)0x8024C008),
+
+ /// A driver error not covered by another WU_E_DRV_* code.
+ WU_E_DRV_UNEXPECTED = unchecked((int)0x8024CFFF),
+
+ /// An operation failed because Windows Update Agent is shutting down.
+ WU_E_DS_SHUTDOWN = unchecked((int)0x80248000),
+
+ /// An operation failed because the data store was in use.
+ WU_E_DS_INUSE = unchecked((int)0x80248001),
+
+ /// The current and expected states of the data store do not match.
+ WU_E_DS_INVALID = unchecked((int)0x80248002),
+
+ /// The data store is missing a table.
+ WU_E_DS_TABLEMISSING = unchecked((int)0x80248003),
+
+ /// The data store contains a table with unexpected columns.
+ WU_E_DS_TABLEINCORRECT = unchecked((int)0x80248004),
+
+ /// A table could not be opened because the table is not in the data store.
+ WU_E_DS_INVALIDTABLENAME = unchecked((int)0x80248005),
+
+ /// The current and expected versions of the data store do not match.
+ WU_E_DS_BADVERSION = unchecked((int)0x80248006),
+
+ /// The information requested is not in the data store.
+ WU_E_DS_NODATA = unchecked((int)0x80248007),
+
+ /// The data store is missing required information or has a NULL in a table column that requires a non-null value.
+ WU_E_DS_MISSINGDATA = unchecked((int)0x80248008),
+
+ /// The data store is missing required information or has a reference to missing license terms, file, localized property or linked row.
+ WU_E_DS_MISSINGREF = unchecked((int)0x80248009),
+
+ /// The update was not processed because its update handler could not be recognized.
+ WU_E_DS_UNKNOWNHANDLER = unchecked((int)0x8024800A),
+
+ /// The update was not deleted because it is still referenced by one or more services.
+ WU_E_DS_CANTDELETE = unchecked((int)0x8024800B),
+
+ /// The data store section could not be locked within the allotted time.
+ WU_E_DS_LOCKTIMEOUTEXPIRED = unchecked((int)0x8024800C),
+
+ /// The category was not added because it contains no parent categories and is not a top-level category itself.
+ WU_E_DS_NOCATEGORIES = unchecked((int)0x8024800D),
+
+ /// The row was not added because an existing row has the same primary key.
+ WU_E_DS_ROWEXISTS = unchecked((int)0x8024800E),
+
+ /// The data store could not be initialized because it was locked by another process.
+ WU_E_DS_STOREFILELOCKED = unchecked((int)0x8024800F),
+
+ /// The data store is not allowed to be registered with COM in the current process.
+ WU_E_DS_CANNOTREGISTER = unchecked((int)0x80248010),
+
+ /// Could not create a data store object in another process.
+ WU_E_DS_UNABLETOSTART = unchecked((int)0x80248011),
+
+ /// The server sent the same update to the client with two different revision IDs.
+ WU_E_DS_DUPLICATEUPDATEID = unchecked((int)0x80248013),
+
+ /// An operation did not complete because the service is not in the data store.
+ WU_E_DS_UNKNOWNSERVICE = unchecked((int)0x80248014),
+
+ /// An operation did not complete because the registration of the service has expired.
+ WU_E_DS_SERVICEEXPIRED = unchecked((int)0x80248015),
+
+ /// A request to hide an update was declined because it is a mandatory update or because it was deployed with a deadline.
+ WU_E_DS_DECLINENOTALLOWED = unchecked((int)0x80248016),
+
+ /// A table was not closed because it is not associated with the session.
+ WU_E_DS_TABLESESSIONMISMATCH = unchecked((int)0x80248017),
+
+ /// A table was not closed because it is not associated with the session.
+ WU_E_DS_SESSIONLOCKMISMATCH = unchecked((int)0x80248018),
+
+ /// A request to remove the Windows Update service or to unregister it with Automatic Updates was declined because it is a built-in service and/or Automatic Updates cannot fall back to another service.
+ WU_E_DS_NEEDWINDOWSSERVICE = unchecked((int)0x80248019),
+
+ /// A request was declined because the operation is not allowed.
+ WU_E_DS_INVALIDOPERATION = unchecked((int)0x8024801A),
+
+ /// The schema of the current data store and the schema of a table in a backup XML document do not match.
+ WU_E_DS_SCHEMAMISMATCH = unchecked((int)0x8024801B),
+
+ /// The data store requires a session reset; release the session and retry with a new session.
+ WU_E_DS_RESETREQUIRED = unchecked((int)0x8024801C),
+
+ /// A data store operation did not complete because it was requested with an impersonated identity.
+ WU_E_DS_IMPERSONATED = unchecked((int)0x8024801D),
+
+ /// An operation against update metadata did not complete because the data was never received from server.
+ WU_E_DS_DATANOTAVAILABLE = unchecked((int)0x8024801E),
+
+ /// An operation against update metadata did not complete because the data was available but not loaded from datastore.
+ WU_E_DS_DATANOTLOADED = unchecked((int)0x8024801F),
+
+ /// A data store operation did not complete because no such update revision is known.
+ WU_E_DS_NODATA_NOSUCHREVISION = unchecked((int)0x80248020),
+
+ /// A data store operation did not complete because no such update is known.
+ WU_E_DS_NODATA_NOSUCHUPDATE = unchecked((int)0x80248021),
+
+ /// A data store operation did not complete because an update's EULA information is missing.
+ WU_E_DS_NODATA_EULA = unchecked((int)0x80248022),
+
+ /// A data store operation did not complete because a service's information is missing.
+ WU_E_DS_NODATA_SERVICE = unchecked((int)0x80248023),
+
+ /// A data store operation did not complete because a service's synchronization information is missing.
+ WU_E_DS_NODATA_COOKIE = unchecked((int)0x80248024),
+
+ /// A data store operation did not complete because a timer's information is missing.
+ WU_E_DS_NODATA_TIMER = unchecked((int)0x80248025),
+
+ /// A data store operation did not complete because a download's information is missing.
+ WU_E_DS_NODATA_CCR = unchecked((int)0x80248026),
+
+ /// A data store operation did not complete because a file's information is missing.
+ WU_E_DS_NODATA_FILE = unchecked((int)0x80248027),
+
+ /// A data store operation did not complete because a download job's information is missing.
+ WU_E_DS_NODATA_DOWNLOADJOB = unchecked((int)0x80248028),
+
+ /// A data store operation did not complete because a service's timestamp information is missing.
+ WU_E_DS_NODATA_TMI = unchecked((int)0x80248029),
+
+ /// A data store error not covered by another WU_E_DS_* code.
+ WU_E_DS_UNEXPECTED = unchecked((int)0x80248FFF),
+
+ /// Parsing of the rule file failed.
+ WU_E_INVENTORY_PARSEFAILED = unchecked((int)0x80249001),
+
+ /// Failed to get the requested inventory type from the server.
+ WU_E_INVENTORY_GET_INVENTORY_TYPE_FAILED = unchecked((int)0x80249002),
+
+ /// Failed to upload inventory result to the server.
+ WU_E_INVENTORY_RESULT_UPLOAD_FAILED = unchecked((int)0x80249003),
+
+ /// There was an inventory error not covered by another error code.
+ WU_E_INVENTORY_UNEXPECTED = unchecked((int)0x80249004),
+
+ /// A WMI error occurred when enumerating the instances for a particular class.
+ WU_E_INVENTORY_WMI_ERROR = unchecked((int)0x80249005),
+
+ /// Automatic Updates was unable to service incoming requests.
+ WU_E_AU_NOSERVICE = unchecked((int)0x8024A000),
+
+ /// The old version of the Automatic Updates client has stopped because the WSUS server has been upgraded.
+ WU_E_AU_NONLEGACYSERVER = unchecked((int)0x8024A002),
+
+ /// The old version of the Automatic Updates client was disabled.
+ WU_E_AU_LEGACYCLIENTDISABLED = unchecked((int)0x8024A003),
+
+ /// Automatic Updates was unable to process incoming requests because it was paused.
+ WU_E_AU_PAUSED = unchecked((int)0x8024A004),
+
+ /// No unmanaged service is registered with AU.
+ WU_E_AU_NO_REGISTERED_SERVICE = unchecked((int)0x8024A005),
+
+ /// The default service registered with AU changed during the search.
+ WU_E_AU_DETECT_SVCID_MISMATCH = unchecked((int)0x8024A006),
+
+ /// A reboot is in progress.
+ WU_E_REBOOT_IN_PROGRESS = unchecked((int)0x8024A007),
+
+ /// Automatic Updates can't process incoming requests while Windows Welcome is running.
+ WU_E_AU_OOBE_IN_PROGRESS = unchecked((int)0x8024A008),
+
+ /// An Automatic Updates error not covered by another WU_E_AU * code.
+ WU_E_AU_UNEXPECTED = unchecked((int)0x8024AFFF),
+
+ /// A request for a remote update handler could not be completed because no remote process is available.
+ WU_E_UH_REMOTEUNAVAILABLE = unchecked((int)0x80242000),
+
+ /// A request for a remote update handler could not be completed because the handler is local only.
+ WU_E_UH_LOCALONLY = unchecked((int)0x80242001),
+
+ /// A request for an update handler could not be completed because the handler could not be recognized.
+ WU_E_UH_UNKNOWNHANDLER = unchecked((int)0x80242002),
+
+ /// A remote update handler could not be created because one already exists.
+ WU_E_UH_REMOTEALREADYACTIVE = unchecked((int)0x80242003),
+
+ /// A request for the handler to install (uninstall) an update could not be completed because the update does not support install (uninstall).
+ WU_E_UH_DOESNOTSUPPORTACTION = unchecked((int)0x80242004),
+
+ /// An operation did not complete because the wrong handler was specified.
+ WU_E_UH_WRONGHANDLER = unchecked((int)0x80242005),
+
+ /// A handler operation could not be completed because the update contains invalid metadata.
+ WU_E_UH_INVALIDMETADATA = unchecked((int)0x80242006),
+
+ /// An operation could not be completed because the installer exceeded the time limit.
+ WU_E_UH_INSTALLERHUNG = unchecked((int)0x80242007),
+
+ /// An operation being done by the update handler was cancelled.
+ WU_E_UH_OPERATIONCANCELLED = unchecked((int)0x80242008),
+
+ /// An operation could not be completed because the handler-specific metadata is invalid.
+ WU_E_UH_BADHANDLERXML = unchecked((int)0x80242009),
+
+ /// A request to the handler to install an update could not be completed because the update requires user input.
+ WU_E_UH_CANREQUIREINPUT = unchecked((int)0x8024200A),
+
+ /// The installer failed to install (uninstall) one or more updates.
+ WU_E_UH_INSTALLERFAILURE = unchecked((int)0x8024200B),
+
+ /// The update handler should download self-contained content rather than delta-compressed content for the update.
+ WU_E_UH_FALLBACKTOSELFCONTAINED = unchecked((int)0x8024200C),
+
+ /// The update handler did not install the update because it needs to be downloaded again.
+ WU_E_UH_NEEDANOTHERDOWNLOAD = unchecked((int)0x8024200D),
+
+ /// The update handler failed to send notification of the status of the install (uninstall) operation.
+ WU_E_UH_NOTIFYFAILURE = unchecked((int)0x8024200E),
+
+ /// The file names contained in the update metadata and in the update package are inconsistent.
+ WU_E_UH_INCONSISTENT_FILE_NAMES = unchecked((int)0x8024200F),
+
+ /// The update handler failed to fall back to the self-contained content.
+ WU_E_UH_FALLBACKERROR = unchecked((int)0x80242010),
+
+ /// The update handler has exceeded the maximum number of download requests.
+ WU_E_UH_TOOMANYDOWNLOADREQUESTS = unchecked((int)0x80242011),
+
+ /// The update handler has received an unexpected response from CBS.
+ WU_E_UH_UNEXPECTEDCBSRESPONSE = unchecked((int)0x80242012),
+
+ /// The update metadata contains an invalid CBS package identifier.
+ WU_E_UH_BADCBSPACKAGEID = unchecked((int)0x80242013),
+
+ /// The post-reboot operation for the update is still in progress.
+ WU_E_UH_POSTREBOOTSTILLPENDING = unchecked((int)0x80242014),
+
+ /// The result of the post-reboot operation for the update could not be determined.
+ WU_E_UH_POSTREBOOTRESULTUNKNOWN = unchecked((int)0x80242015),
+
+ /// The state of the update after its post-reboot operation has completed is unexpected.
+ WU_E_UH_POSTREBOOTUNEXPECTEDSTATE = unchecked((int)0x80242016),
+
+ /// The OS servicing stack must be updated before this update is downloaded or installed.
+ WU_E_UH_NEW_SERVICING_STACK_REQUIRED = unchecked((int)0x80242017),
+
+ /// A callback installer called back with an error.
+ WU_E_UH_CALLED_BACK_FAILURE = unchecked((int)0x80242018),
+
+ /// The custom installer signature did not match the signature required by the update.
+ WU_E_UH_CUSTOMINSTALLER_INVALID_SIGNATURE = unchecked((int)0x80242019),
+
+ /// The installer does not support the installation configuration.
+ WU_E_UH_UNSUPPORTED_INSTALLCONTEXT = unchecked((int)0x8024201A),
+
+ /// The targeted session for install is invalid.
+ WU_E_UH_INVALID_TARGETSESSION = unchecked((int)0x8024201B),
+
+ /// The handler failed to decrypt the update files.
+ WU_E_UH_DECRYPTFAILURE = unchecked((int)0x8024201C),
+
+ /// The update handler is disabled until the system reboots.
+ WU_E_UH_HANDLER_DISABLEDUNTILREBOOT = unchecked((int)0x8024201D),
+
+ /// The AppX infrastructure is not present on the system.
+ WU_E_UH_APPX_NOT_PRESENT = unchecked((int)0x8024201E),
+
+ /// The update cannot be committed because it has not been previously installed or staged.
+ WU_E_UH_NOTREADYTOCOMMIT = unchecked((int)0x8024201F),
+
+ /// The specified volume is not a valid AppX package volume.
+ WU_E_UH_APPX_INVALID_PACKAGE_VOLUME = unchecked((int)0x80242020),
+
+ /// The configured default storage volume is unavailable.
+ WU_E_UH_APPX_DEFAULT_PACKAGE_VOLUME_UNAVAILABLE = unchecked((int)0x80242021),
+
+ /// The volume on which the application is installed is unavailable.
+ WU_E_UH_APPX_INSTALLED_PACKAGE_VOLUME_UNAVAILABLE = unchecked((int)0x80242022),
+
+ /// The specified package family is not present on the system.
+ WU_E_UH_APPX_PACKAGE_FAMILY_NOT_FOUND = unchecked((int)0x80242023),
+
+ /// Unable to find a package volume marked as system.
+ WU_E_UH_APPX_SYSTEM_VOLUME_NOT_FOUND = unchecked((int)0x80242024),
+
+ /// An update handler error not covered by another WU_E_UH_* code.
+ WU_E_UH_UNEXPECTED = unchecked((int)0x80242FFF),
+
+ /// A download manager operation could not be completed because the requested file does not have a URL.
+ WU_E_DM_URLNOTAVAILABLE = unchecked((int)0x80246001),
+
+ /// A download manager operation could not be completed because the file digest was not recognized.
+ WU_E_DM_INCORRECTFILEHASH = unchecked((int)0x80246002),
+
+ /// A download manager operation could not be completed because the file metadata requested an unrecognized hash algorithm.
+ WU_E_DM_UNKNOWNALGORITHM = unchecked((int)0x80246003),
+
+ /// An operation could not be completed because a download request is required from the download handler.
+ WU_E_DM_NEEDDOWNLOADREQUEST = unchecked((int)0x80246004),
+
+ /// A download manager operation could not be completed because the network connection was unavailable.
+ WU_E_DM_NONETWORK = unchecked((int)0x80246005),
+
+ /// A download manager operation could not be completed because the version of Background Intelligent Transfer Service (BITS) is incompatible.
+ WU_E_DM_WRONGBITSVERSION = unchecked((int)0x80246006),
+
+ /// The update has not been downloaded.
+ WU_E_DM_NOTDOWNLOADED = unchecked((int)0x80246007),
+
+ /// A download manager operation failed because the download manager was unable to connect the Background Intelligent Transfer Service (BITS).
+ WU_E_DM_FAILTOCONNECTTOBITS = unchecked((int)0x80246008),
+
+ /// A download manager operation failed because there was an unspecified Background Intelligent Transfer Service (BITS) transfer error.
+ WU_E_DM_BITSTRANSFERERROR = unchecked((int)0x80246009),
+
+ /// A download must be restarted because the location of the source of the download has changed.
+ WU_E_DM_DOWNLOADLOCATIONCHANGED = unchecked((int)0x8024600A),
+
+ /// A download must be restarted because the update content changed in a new revision.
+ WU_E_DM_CONTENTCHANGED = unchecked((int)0x8024600B),
+
+ /// A download failed because the current network limits downloads by update size for the update service.
+ WU_E_DM_DOWNLOADLIMITEDBYUPDATESIZE = unchecked((int)0x8024600C),
+
+ /// The download failed because the client was denied authorization to download the content.
+ WU_E_DM_UNAUTHORIZED = unchecked((int)0x8024600E),
+
+ /// The download failed because the user token associated with the BITS job no longer exists.
+ WU_E_DM_BG_ERROR_TOKEN_REQUIRED = unchecked((int)0x8024600F),
+
+ /// The sandbox directory for the downloaded update was not found.
+ WU_E_DM_DOWNLOADSANDBOXNOTFOUND = unchecked((int)0x80246010),
+
+ /// The downloaded update has an unknown file path.
+ WU_E_DM_DOWNLOADFILEPATHUNKNOWN = unchecked((int)0x80246011),
+
+ /// One or more of the files for the downloaded update is missing.
+ WU_E_DM_DOWNLOADFILEMISSING = unchecked((int)0x80246012),
+
+ /// An attempt was made to access a downloaded update that has already been removed.
+ WU_E_DM_UPDATEREMOVED = unchecked((int)0x80246013),
+
+ /// Windows Update couldn't find a needed portion of a downloaded update's file.
+ WU_E_DM_READRANGEFAILED = unchecked((int)0x80246014),
+
+ /// The download failed because the client was denied authorization to download the content due to no user logged on.
+ WU_E_DM_UNAUTHORIZED_NO_USER = unchecked((int)0x80246016),
+
+ /// The download failed because the local user was denied authorization to download the content.
+ WU_E_DM_UNAUTHORIZED_LOCAL_USER = unchecked((int)0x80246017),
+
+ /// The download failed because the domain user was denied authorization to download the content.
+ WU_E_DM_UNAUTHORIZED_DOMAIN_USER = unchecked((int)0x80246018),
+
+ /// The download failed because the MSA account associated with the user was denied authorization to download the content.
+ WU_E_DM_UNAUTHORIZED_MSA_USER = unchecked((int)0x80246019),
+
+ /// The download will be continued by falling back to BITS to download the content.
+ WU_E_DM_FALLINGBACKTOBITS = unchecked((int)0x8024601A),
+
+ /// Another caller has requested download to a different volume.
+ WU_E_DM_DOWNLOAD_VOLUME_CONFLICT = unchecked((int)0x8024601B),
+
+ /// The hash of the update's sandbox does not match the expected value.
+ WU_E_DM_SANDBOX_HASH_MISMATCH = unchecked((int)0x8024601C),
+
+ /// The hard reserve id specified conflicts with an id from another caller.
+ WU_E_DM_HARDRESERVEID_CONFLICT = unchecked((int)0x8024601D),
+
+ /// The update has to be downloaded via DO.
+ WU_E_DM_DOSVC_REQUIRED = unchecked((int)0x8024601E),
+
+ /// There was a download manager error not covered by another WU_E_DM_* error code.
+ WU_E_DM_UNEXPECTED = unchecked((int)0x80246FFF),
+
+ /// Windows Update Agent could not be updated because an INF file contains invalid information.
+ WU_E_SETUP_INVALID_INFDATA = unchecked((int)0x8024D001),
+
+ /// Windows Update Agent could not be updated because the wuident.cab file contains invalid information.
+ WU_E_SETUP_INVALID_IDENTDATA = unchecked((int)0x8024D002),
+
+ /// Windows Update Agent could not be updated because of an internal error that caused setup initialization to be performed twice.
+ WU_E_SETUP_ALREADY_INITIALIZED = unchecked((int)0x8024D003),
+
+ /// Windows Update Agent could not be updated because setup initialization never completed successfully.
+ WU_E_SETUP_NOT_INITIALIZED = unchecked((int)0x8024D004),
+
+ /// Windows Update Agent could not be updated because the versions specified in the INF do not match the actual source file versions.
+ WU_E_SETUP_SOURCE_VERSION_MISMATCH = unchecked((int)0x8024D005),
+
+ /// Windows Update Agent could not be updated because a WUA file on the target system is newer than the corresponding source file.
+ WU_E_SETUP_TARGET_VERSION_GREATER = unchecked((int)0x8024D006),
+
+ /// Windows Update Agent could not be updated because regsvr32.exe returned an error.
+ WU_E_SETUP_REGISTRATION_FAILED = unchecked((int)0x8024D007),
+
+ /// An update to the Windows Update Agent was skipped because previous attempts to update have failed.
+ WU_E_SELFUPDATE_SKIP_ON_FAILURE = unchecked((int)0x8024D008),
+
+ /// An update to the Windows Update Agent was skipped due to a directive in the wuident.cab file.
+ WU_E_SETUP_SKIP_UPDATE = unchecked((int)0x8024D009),
+
+ /// Windows Update Agent could not be updated because the current system configuration is not supported.
+ WU_E_SETUP_UNSUPPORTED_CONFIGURATION = unchecked((int)0x8024D00A),
+
+ /// Windows Update Agent could not be updated because the system is configured to block the update.
+ WU_E_SETUP_BLOCKED_CONFIGURATION = unchecked((int)0x8024D00B),
+
+ /// Windows Update Agent could not be updated because a restart of the system is required.
+ WU_E_SETUP_REBOOT_TO_FIX = unchecked((int)0x8024D00C),
+
+ /// Windows Update Agent setup is already running.
+ WU_E_SETUP_ALREADYRUNNING = unchecked((int)0x8024D00D),
+
+ /// Windows Update Agent setup package requires a reboot to complete installation.
+ WU_E_SETUP_REBOOTREQUIRED = unchecked((int)0x8024D00E),
+
+ /// Windows Update Agent could not be updated because the setup handler failed during execution.
+ WU_E_SETUP_HANDLER_EXEC_FAILURE = unchecked((int)0x8024D00F),
+
+ /// Windows Update Agent could not be updated because the registry contains invalid information.
+ WU_E_SETUP_INVALID_REGISTRY_DATA = unchecked((int)0x8024D010),
+
+ /// Windows Update Agent must be updated before search can continue.
+ WU_E_SELFUPDATE_REQUIRED = unchecked((int)0x8024D011),
+
+ /// Windows Update Agent must be updated before search can continue. An administrator is required to perform the operation.
+ WU_E_SELFUPDATE_REQUIRED_ADMIN = unchecked((int)0x8024D012),
+
+ /// Windows Update Agent could not be updated because the server does not contain update information for this version.
+ WU_E_SETUP_WRONG_SERVER_VERSION = unchecked((int)0x8024D013),
+
+ /// Windows Update Agent is successfully updated, but a reboot is required to complete the setup.
+ WU_E_SETUP_DEFERRABLE_REBOOT_PENDING = unchecked((int)0x8024D014),
+
+ /// Windows Update Agent is successfully updated, but a reboot is required to complete the setup.
+ WU_E_SETUP_NON_DEFERRABLE_REBOOT_PENDING = unchecked((int)0x8024D015),
+
+ /// Windows Update Agent could not be updated because of an unknown error.
+ WU_E_SETUP_FAIL = unchecked((int)0x8024D016),
+
+ /// Windows Update Agent could not be updated because of an error not covered by another WU_E_SETUP_* error code.
+ WU_E_SETUP_UNEXPECTED = unchecked((int)0x8024DFFF),
+
+ /// An expression evaluator operation could not be completed because an expression was unrecognized.
+ WU_E_EE_UNKNOWN_EXPRESSION = unchecked((int)0x8024E001),
+
+ /// An expression evaluator operation could not be completed because an expression was invalid.
+ WU_E_EE_INVALID_EXPRESSION = unchecked((int)0x8024E002),
+
+ /// An expression evaluator operation could not be completed because an expression contains an incorrect number of metadata nodes.
+ WU_E_EE_MISSING_METADATA = unchecked((int)0x8024E003),
+
+ /// An expression evaluator operation could not be completed because the version of the serialized expression data is invalid.
+ WU_E_EE_INVALID_VERSION = unchecked((int)0x8024E004),
+
+ /// The expression evaluator could not be initialized.
+ WU_E_EE_NOT_INITIALIZED = unchecked((int)0x8024E005),
+
+ /// An expression evaluator operation could not be completed because there was an invalid attribute.
+ WU_E_EE_INVALID_ATTRIBUTEDATA = unchecked((int)0x8024E006),
+
+ /// An expression evaluator operation could not be completed because the cluster state of the computer could not be determined.
+ WU_E_EE_CLUSTER_ERROR = unchecked((int)0x8024E007),
+
+ /// There was an expression evaluator error not covered by another WU_E_EE_* error code.
+ WU_E_EE_UNEXPECTED = unchecked((int)0x8024EFFF),
+
+ /// The results of download and installation could not be read from the registry due to an unrecognized data format version.
+ WU_E_INSTALLATION_RESULTS_UNKNOWN_VERSION = unchecked((int)0x80243001),
+
+ /// The results of download and installation could not be read from the registry due to an invalid data format.
+ WU_E_INSTALLATION_RESULTS_INVALID_DATA = unchecked((int)0x80243002),
+
+ /// The results of download and installation are not available; the operation may have failed to start.
+ WU_E_INSTALLATION_RESULTS_NOT_FOUND = unchecked((int)0x80243003),
+
+ /// A failure occurred when trying to create an icon in the taskbar notification area.
+ WU_E_TRAYICON_FAILURE = unchecked((int)0x80243004),
+
+ /// Unable to show UI when in non-UI mode; WU client UI modules may not be installed.
+ WU_E_NON_UI_MODE = unchecked((int)0x80243FFD),
+
+ /// Unsupported version of WU client UI exported functions.
+ WU_E_WUCLTUI_UNSUPPORTED_VERSION = unchecked((int)0x80243FFE),
+
+ /// There was a user interface error not covered by another WU_E_AUCLIENT_* error code.
+ WU_E_AUCLIENT_UNEXPECTED = unchecked((int)0x80243FFF),
+
+ /// The event cache file was defective.
+ WU_E_REPORTER_EVENTCACHECORRUPT = unchecked((int)0x8024F001),
+
+ /// The XML in the event namespace descriptor could not be parsed.
+ WU_E_REPORTER_EVENTNAMESPACEPARSEFAILED = unchecked((int)0x8024F002),
+
+ /// The XML in the event namespace descriptor could not be parsed.
+ WU_E_INVALID_EVENT = unchecked((int)0x8024F003),
+
+ /// The server rejected an event because the server was too busy.
+ WU_E_SERVER_BUSY = unchecked((int)0x8024F004),
+
+ /// The specified callback cookie is not found.
+ WU_E_CALLBACK_COOKIE_NOT_FOUND = unchecked((int)0x8024F005),
+
+ /// There was a reporter error not covered by another error code.
+ WU_E_REPORTER_UNEXPECTED = unchecked((int)0x8024FFFF),
+
+ /// An operation could not be completed because the scan package was invalid.
+ WU_E_OL_INVALID_SCANFILE = unchecked((int)0x80247001),
+
+ /// An operation could not be completed because the scan package requires a greater version of the Windows Update Agent.
+ WU_E_OL_NEWCLIENT_REQUIRED = unchecked((int)0x80247002),
+
+ /// An invalid event payload was specified.
+ WU_E_INVALID_EVENT_PAYLOAD = unchecked((int)0x80247003),
+
+ /// The size of the event payload submitted is invalid.
+ WU_E_INVALID_EVENT_PAYLOADSIZE = unchecked((int)0x80247004),
+
+ /// The service is not registered.
+ WU_E_SERVICE_NOT_REGISTERED = unchecked((int)0x80247005),
+
+ /// Search using the scan package failed.
+ WU_E_OL_UNEXPECTED = unchecked((int)0x80247FFF),
+
+ /// No operation was required by update metadata verification.
+ WU_E_METADATA_NOOP = unchecked((int)0x80247100),
+
+ /// The binary encoding of metadata config data was invalid.
+ WU_E_METADATA_CONFIG_INVALID_BINARY_ENCODING = unchecked((int)0x80247101),
+
+ /// Unable to fetch required configuration for metadata signature verification.
+ WU_E_METADATA_FETCH_CONFIG = unchecked((int)0x80247102),
+
+ /// A metadata verification operation failed due to an invalid parameter.
+ WU_E_METADATA_INVALID_PARAMETER = unchecked((int)0x80247104),
+
+ /// A metadata verification operation failed due to reasons not covered by another error code.
+ WU_E_METADATA_UNEXPECTED = unchecked((int)0x80247105),
+
+ /// None of the update metadata had verification data, which may be disabled on the update server.
+ WU_E_METADATA_NO_VERIFICATION_DATA = unchecked((int)0x80247106),
+
+ /// The fragment signing configuration used for verifying update metadata signatures was bad.
+ WU_E_METADATA_BAD_FRAGMENTSIGNING_CONFIG = unchecked((int)0x80247107),
+
+ /// There was an unexpected operational failure while parsing fragment signing configuration.
+ WU_E_METADATA_FAILURE_PROCESSING_FRAGMENTSIGNING_CONFIG = unchecked((int)0x80247108),
+
+ /// Required xml data was missing from configuration.
+ WU_E_METADATA_XML_MISSING = unchecked((int)0x80247120),
+
+ /// Required fragmentsigning data was missing from xml configuration.
+ WU_E_METADATA_XML_FRAGMENTSIGNING_MISSING = unchecked((int)0x80247121),
+
+ /// Required mode data was missing from xml configuration.
+ WU_E_METADATA_XML_MODE_MISSING = unchecked((int)0x80247122),
+
+ /// An invalid metadata enforcement mode was detected.
+ WU_E_METADATA_XML_MODE_INVALID = unchecked((int)0x80247123),
+
+ /// An invalid timestamp validity window configuration was detected.
+ WU_E_METADATA_XML_VALIDITY_INVALID = unchecked((int)0x80247124),
+
+ /// Required leaf certificate data was missing from xml configuration.
+ WU_E_METADATA_XML_LEAFCERT_MISSING = unchecked((int)0x80247125),
+
+ /// Required intermediate certificate data was missing from xml configuration.
+ WU_E_METADATA_XML_INTERMEDIATECERT_MISSING = unchecked((int)0x80247126),
+
+ /// Required leaf certificate id attribute was missing from xml configuration.
+ WU_E_METADATA_XML_LEAFCERT_ID_MISSING = unchecked((int)0x80247127),
+
+ /// Required certificate base64CerData attribute was missing from xml configuration.
+ WU_E_METADATA_XML_BASE64CERDATA_MISSING = unchecked((int)0x80247128),
+
+ /// The metadata for an update was found to have a bad or invalid digital signature.
+ WU_E_METADATA_BAD_SIGNATURE = unchecked((int)0x80247140),
+
+ /// An unsupported hash algorithm for metadata verification was specified.
+ WU_E_METADATA_UNSUPPORTED_HASH_ALG = unchecked((int)0x80247141),
+
+ /// An error occurred during an update's metadata signature verification.
+ WU_E_METADATA_SIGNATURE_VERIFY_FAILED = unchecked((int)0x80247142),
+
+ /// An failure occurred while verifying trust for metadata signing certificate chains.
+ WU_E_METADATATRUST_CERTIFICATECHAIN_VERIFICATION = unchecked((int)0x80247150),
+
+ /// A metadata signing certificate had an untrusted certificate chain.
+ WU_E_METADATATRUST_UNTRUSTED_CERTIFICATECHAIN = unchecked((int)0x80247151),
+
+ /// An expected metadata timestamp token was missing.
+ WU_E_METADATA_TIMESTAMP_TOKEN_MISSING = unchecked((int)0x80247160),
+
+ /// A metadata Timestamp token failed verification.
+ WU_E_METADATA_TIMESTAMP_TOKEN_VERIFICATION_FAILED = unchecked((int)0x80247161),
+
+ /// A metadata timestamp token signer certificate chain was untrusted.
+ WU_E_METADATA_TIMESTAMP_TOKEN_UNTRUSTED = unchecked((int)0x80247162),
+
+ /// A metadata signature timestamp token was no longer within the validity window.
+ WU_E_METADATA_TIMESTAMP_TOKEN_VALIDITY_WINDOW = unchecked((int)0x80247163),
+
+ /// A metadata timestamp token failed signature validation
+ WU_E_METADATA_TIMESTAMP_TOKEN_SIGNATURE = unchecked((int)0x80247164),
+
+ /// A metadata timestamp token certificate failed certificate chain verification.
+ WU_E_METADATA_TIMESTAMP_TOKEN_CERTCHAIN = unchecked((int)0x80247165),
+
+ /// A failure occurred when refreshing a missing timestamp token from the network.
+ WU_E_METADATA_TIMESTAMP_TOKEN_REFRESHONLINE = unchecked((int)0x80247166),
+
+ /// All update metadata verification timestamp tokens from the timestamp token cache are invalid.
+ WU_E_METADATA_TIMESTAMP_TOKEN_ALL_BAD = unchecked((int)0x80247167),
+
+ /// No update metadata verification timestamp tokens exist in the timestamp token cache.
+ WU_E_METADATA_TIMESTAMP_TOKEN_NODATA = unchecked((int)0x80247168),
+
+ /// An error occurred during cache lookup of update metadata verification timestamp token.
+ WU_E_METADATA_TIMESTAMP_TOKEN_CACHELOOKUP = unchecked((int)0x80247169),
+
+ /// An metadata timestamp token validity window failed unexpectedly due to reasons not covered by another error code.
+ WU_E_METADATA_TIMESTAMP_TOKEN_VALIDITYWINDOW_UNEXPECTED = unchecked((int)0x8024717E),
+
+ /// An metadata timestamp token verification operation failed due to reasons not covered by another error code.
+ WU_E_METADATA_TIMESTAMP_TOKEN_UNEXPECTED = unchecked((int)0x8024717F),
+
+ /// An expected metadata signing certificate was missing.
+ WU_E_METADATA_CERT_MISSING = unchecked((int)0x80247180),
+
+ /// The transport encoding of a metadata signing leaf certificate was malformed.
+ WU_E_METADATA_LEAFCERT_BAD_TRANSPORT_ENCODING = unchecked((int)0x80247181),
+
+ /// The transport encoding of a metadata signing intermediate certificate was malformed.
+ WU_E_METADATA_INTCERT_BAD_TRANSPORT_ENCODING = unchecked((int)0x80247182),
+
+ /// A metadata certificate chain was untrusted.
+ WU_E_METADATA_CERT_UNTRUSTED = unchecked((int)0x80247183),
+
+ /// The task is currently in progress.
+ WU_E_WUTASK_INPROGRESS = unchecked((int)0x8024B001),
+
+ /// The operation cannot be completed since the task status is currently disabled.
+ WU_E_WUTASK_STATUS_DISABLED = unchecked((int)0x8024B002),
+
+ /// The operation cannot be completed since the task is not yet started.
+ WU_E_WUTASK_NOT_STARTED = unchecked((int)0x8024B003),
+
+ /// The task was stopped and needs to be run again to complete.
+ WU_E_WUTASK_RETRY = unchecked((int)0x8024B004),
+
+ /// Cannot cancel a non-scheduled install.
+ WU_E_WUTASK_CANCELINSTALL_DISALLOWED = unchecked((int)0x8024B005),
+
+ /// Hardware capability meta data was not found after a sync with the service.
+ WU_E_UNKNOWN_HARDWARECAPABILITY = unchecked((int)0x8024B101),
+
+ /// Hardware capability meta data was malformed and/or failed to parse.
+ WU_E_BAD_XML_HARDWARECAPABILITY = unchecked((int)0x8024B102),
+
+ /// Unable to complete action due to WMI dependency, which isn't supported on this platform.
+ WU_E_WMI_NOT_SUPPORTED = unchecked((int)0x8024B103),
+
+ /// Merging of the update is not allowed
+ WU_E_UPDATE_MERGE_NOT_ALLOWED = unchecked((int)0x8024B104),
+
+ /// Installing merged updates only. So skipping non mergeable updates.
+ WU_E_SKIPPED_UPDATE_INSTALLATION = unchecked((int)0x8024B105),
+
+ /// SLS response returned invalid revision number.
+ WU_E_SLS_INVALID_REVISION = unchecked((int)0x8024B201),
+
+ /// File signature validation fails to find valid RSA signature on infrastructure payload.
+ WU_E_FILETRUST_DUALSIGNATURE_RSA = unchecked((int)0x8024B301),
+
+ /// File signature validation fails to find valid ECC signature on infrastructure payload.
+ WU_E_FILETRUST_DUALSIGNATURE_ECC = unchecked((int)0x8024B302),
+
+ /// The subject is not trusted by WU for the specified action.
+ WU_E_TRUST_SUBJECT_NOT_TRUSTED = unchecked((int)0x8024B303),
+
+ /// Unknown trust provider for WU.
+ WU_E_TRUST_PROVIDER_UNKNOWN = unchecked((int)0x8024B304),
+ }
+}
\ No newline at end of file
diff --git a/UnitTests/PInvoke/WUApi/WUApi.csproj b/UnitTests/PInvoke/WUApi/WUApi.csproj
index 1158815e..8636f0d2 100644
--- a/UnitTests/PInvoke/WUApi/WUApi.csproj
+++ b/UnitTests/PInvoke/WUApi/WUApi.csproj
@@ -3,6 +3,17 @@
UnitTest.PInvoke.WUApi
-
+
+ tlbimp
+ 0
+ 2
+ b596cc9f-56e5-419e-a622-e01bb457431e
+ 0
+ false
+ true
+
+
+
+
\ No newline at end of file
diff --git a/UnitTests/PInvoke/WUApi/WUApiTests.cs b/UnitTests/PInvoke/WUApi/WUApiTests.cs
index edf4fac5..413fdb96 100644
--- a/UnitTests/PInvoke/WUApi/WUApiTests.cs
+++ b/UnitTests/PInvoke/WUApi/WUApiTests.cs
@@ -1,65 +1,306 @@
-using NUnit.Framework;
+//#define WUTYPELIB
+using NUnit.Framework;
using NUnit.Framework.Internal;
-using System.Collections;
+using System.Collections.Generic;
using System.Linq;
-using Vanara.Extensions.Reflection;
+using System.Threading;
+using System.Threading.Tasks;
+#if !WUTYPELIB
+using Vanara.WindowsUpdate;
using static Vanara.PInvoke.WUApi;
+#else
+using WUApiLib;
+#endif
namespace Vanara.PInvoke.Tests;
[TestFixture]
public class WUApiTests
{
- private static readonly string[] UpdProps = [ "AutoSelectOnWebSites", "BundledUpdates", "CanRequireSource", "Categories", "Deadline", "DeltaCompressedContentAvailable",
- "DeltaCompressedContentPreferred", "DeploymentAction", "Description", "DownloadContents", "DownloadPriority", "EulaAccepted", "EulaText", "HandlerID",
- "Identity", "Image", "InstallationBehavior", "IsBeta", "IsDownloaded", "IsHidden", "IsInstalled", "IsMandatory", "IsUninstallable", "KBArticleIDs",
- "Languages", "LastDeploymentChangeTime", "MaxDownloadSize", "MinDownloadSize", "MoreInfoUrls", "MsrcSeverity", "RecommendedCpuSpeed",
- "RecommendedHardDiskSpace", "RecommendedMemory", "ReleaseNotes", "SecurityBulletinIDs", "SupersededUpdateIDs", "SupportUrl", "Title", "Type",
- "UninstallationBehavior", "UninstallationNotes", "UninstallationSteps", "KBArticleIDs", "DeploymentAction", "DownloadPriority", "DownloadContents",
- "RebootRequired", "IsPresent", "CveIDs", "BrowseOnly", "PerUser", "AutoSelection", "AutoDownload" ];
+ [Test]
+ public void TestAgent()
+ {
+ WindowsUpdateAgentInfo agent = new();
+ Version? pv = null, ver = null;
+#if !WUTYPELIB
+ Assert.That(() => pv = agent.ProductVersion, Throws.Nothing);
+ Assert.That(() => ver = agent.ApiVersion, Throws.Nothing);
+#endif
+ TestContext.WriteLine($"Version: {pv}, Api: {ver}");
+ }
+
+ [Test]
+ public void TestAuto()
+ {
+ AutomaticUpdates auto = new();
+ auto.WriteValues();
+ //auto.EnableService();
+ auto.DetectNow();
+ auto.Resume();
+ //auto.ShowSettingsDialog();
+
+ //var t = auto.Settings.ScheduledInstallationTime;
+ //auto.Settings.ScheduledInstallationTime = t + 1;
+ //try { auto.Settings.Save(); Assert.That(auto.Settings.ScheduledInstallationTime, Is.EqualTo(t + 1)); }
+ //finally { auto.Settings.ScheduledInstallationTime = t; }
+ }
+
+ [Test]
+ public void TestDownloader()
+ {
+ UpdateDownloader downloader = new();
+ downloader.WriteValues();
+ }
+
+ [Test]
+ public void TestInstaller()
+ {
+ AutomaticUpdates auto = new();
+ if (!auto.ServiceEnabled)
+ {
+ for (int i = 0; i <= 5 && !auto.ServiceEnabled; i++)
+ {
+ auto.EnableService();
+ Thread.Sleep(2000);
+ }
+ Assert.That(auto.ServiceEnabled, Is.True);
+ }
+
+ var autoUpd = new UpdateSearcher().Search("IsInstalled=0").Updates.Where(u => u.AutoSelectOnWebSites).ToList();
+ var dnld = autoUpd.Where(u => !u.IsDownloaded).ToList();
+ if (dnld.Count > 0)
+ new UpdateDownloader(dnld).DownloadAsync(p => p.WriteValues()).Result.WriteValues();
+
+ var res = new UpdateInstaller(autoUpd) { AllowSourcePrompts = false, ForceQuiet = true }.InstallAsync(p => p.WriteValues()).Result;
+ Assert.That(res.HResult, Is.EqualTo((HRESULT)0));
+ res.WriteValues();
+ }
+
+ [Test]
+ public void TestSysInfo()
+ {
+ SystemInformation info = new();
+ info.WriteValues();
+ }
+
+#if !WUTYPELIB
+ [Test]
+ public void TestUpdateHistory()
+ {
+ foreach (UpdateHistoryEntry e in new UpdateHistory())
+ {
+ TestContext.WriteLine(new string('=', 50));
+ e.WriteValues(false);
+ }
+ }
+#endif
[Test]
public void TestUpdateSearch()
{
- IUpdateSession2 sess = new();
- var searcher = sess.CreateUpdateSearcher();
- searcher.IncludePotentiallySupersededUpdates = true;
- var res = searcher.Search("IsInstalled=0");
- foreach (var upd in res.Updates.Cast())
+ UpdateSearcher searcher = new();
+ var res = searcher.Search("");
+ foreach (var upd in res.Updates)
{
TestContext.WriteLine(new string('=', 50));
- foreach (var prop in UpdProps)
- {
- try
- {
- var val = upd.GetPropertyValue