SearchScope enumeration (wuapi.h)

Defines the variety of updates that should be returned by the search: per-machine updates, per-user updates, or both.

Syntax

typedef enum tagSearchScope {
  searchScopeDefault = 0,
  searchScopeMachineOnly = 1,
  searchScopeCurrentUserOnly = 2,
  searchScopeMachineAndCurrentUser = 3,
  searchScopeMachineAndAllUsers = 4,
  searchScopeAllUsers = 5
} SearchScope;

Constants

 
searchScopeDefault
Value: 0
Search by using the default scope (the scope that Automatic Updates would use when searching for updates). This is currently equivalent to search ScopeMachineOnly.
searchScopeMachineOnly
Value: 1
Search only for per-machine updates; exclude all per-user updates.
searchScopeCurrentUserOnly
Value: 2
Search only for per-user updates applicable to the calling user – the user who owns the process which is making the Windows Update Agent (WUA) API call.
searchScopeMachineAndCurrentUser
Value: 3
[Not currently supported.] Search for per-machine updates and for per-user updates applicable to the current user.
searchScopeMachineAndAllUsers
Value: 4
[Not currently supported.] Search for per-machine updates and for per-user updates applicable to any known user accounts on the computer.
searchScopeAllUsers
Value: 5
[Not currently supported.] Search only for per-user updates applicable to any known user accounts on the computer.

Remarks

In versions of the Windows Update Agent that do not support per-user updates (versions that do not support the IUpdateSearcher3 interface), searches will always return only per-machine updates.

Requirements

Requirement Value
Minimum supported client Windows XP, Windows 2000 Professional with SP3 [desktop apps only]
Minimum supported server Windows Server 2003, Windows 2000 Server with SP3 [desktop apps only]
Header wuapi.h