The IUIResourceMgr::ExecuteProgram method, in Configuration Manager, sends a request to the software distribution advertised programs client agent to initiate the execution of a program.

[IDL]
HRESULT ExecuteProgram(
	BSTR sProgramId,
	BSTR sPackageId,
	long bRunOnCompletion
);

Parameters

sProgramId


Data type: BSTRQualifiers: [in]The ID of the program to run.
sPackageId


Data type: BSTRQualifiers: [in]The package ID of the program to run.
bRunOnCompletion


Data type: longQualifiers: [in]Value indicating to the agent if the program is to run when download is complete.

Return Values

An HRESULT code. Possible values include, but are not limited to, the following:

S_OK


The method succeeded.

Remarks

If there are any dependent child programs in the dependency chain that have not been run, they are run before the specified program is run.

This method can be called only in the context of the user who is logged on to the client.

The example demonstrates how to run all available programs on a client.

Requirements

UIResource.dll.

Runtime Requirements

Development Requirements

See Also


Send comments about this topic to Microsoft.