SetSessionDirectoryProperty method of the Win32_TSSessionDirectory class

Sets the SessionDirectoryLocation property or the SessionDirectoryClusterName property for the class.

Syntax

uint32 SetSessionDirectoryProperty(
  [in] string PropertyName,
  [in] string Value
);

Parameters

PropertyName [in]

Type: string

Specifies the property that the method is setting.

SessionDirectoryLocation

The method is setting the SessionDirectoryLocation property.

SessionDirectoryClusterName

The method is setting the SessionDirectoryClusterName property.

Value [in]

Type: string

The new value for the property specified by the PropertyName parameter.

Return value

Type: uint32

Returns 0 on success, otherwise returns a WMI error code. Refer to Remote Desktop Services WMI Provider Error Codes for a list of these values. The method returns an error if the setting is under group policy control.

Remarks

Managed Object Format (MOF) files contain the definitions for Windows Management Instrumentation (WMI) classes. MOF files are not installed as part of the Microsoft Windows Software Development Kit (SDK). They are installed on the server when you add the associated role by using the Server Manager. For more information about MOF files, see Managed Object Format (MOF).

Requirements

Requirement Value
Minimum supported client
None supported
Minimum supported server
Windows Server 2008
Namespace
Root\CIMv2\TerminalServices
MOF
TSCfgWmi.mof
DLL
TSCfgWmi.dll

See also

Win32_TSSessionDirectory