IUserActivitySourceHostInterop::SetActivitySourceHost method (useractivityinterop.h)

Associates host information with either a UserActivityChannel or the UserActivity object.

Syntax

HRESULT SetActivitySourceHost(
  HSTRING activitySourceHost
);

Parameters

activitySourceHost

An HSTRING containing the host to be associated with the user activity.

Return value

If this function succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

The host information for a UserActivity object only needs to set with this method if the UserActivity object was constructed from a source other than a UserActivityChannel, such as by using the UserActivity constructor.

Requirements

Requirement Value
Minimum supported client Windows 10 Build 20348
Minimum supported server Windows 10 Build 20348
Header useractivityinterop.h