GetLocalManagedApplications function
The GetLocalManagedApplications function can be run on the target computer to get a list of managed applications on that computer. The function can also be called in the context of a user to get a list of managed applications for that user. This function only returns applications that can be installed by the Windows Installer.
Syntax
DWORD GetLocalManagedApplications( _In_ BOOL bUserApps, _Out_ LPDWORD pdwApps, _Out_ PLOCALMANAGEDAPPLICATION *prgLocalApps );
Parameters
- bUserApps [in]
-
A value that, if TRUE, the prgLocalApps parameter contains a list of managed applications that applies to the user. If the value of this parameter is FALSE, the prgLocalApps parameter contains a list of managed applications that applies to the local computer.
- pdwApps [out]
-
The address of a DWORD that specifies the number of applications in the list returned by prgLocalApps.
- prgLocalApps [out]
-
The address of an array that contains the list of managed applications. You must call LocalFree to free this array when its contents are no longer required. This parameter cannot be null. The list is returned as a LOCALMANAGEDAPPLICATION structure.
Return value
If the function succeeds, the return value is ERROR_SUCCESS. Otherwise, the function returns one of the system error codes. For a complete list of error codes, see System Error Codes or the header file WinError.h.
Requirements
|
Minimum supported client |
Windows Vista |
|---|---|
|
Minimum supported server |
Windows Server 2008 |
|
Header |
|
|
Library |
|
|
DLL |
|
See also