Compartir a través de


ISmsClient::SetAssignedSite Method

Applies To: System Center Configuration Manager 2007, System Center Configuration Manager 2007 R2, System Center Configuration Manager 2007 R3, System Center Configuration Manager 2007 SP1, System Center Configuration Manager 2007 SP2

The ISmsClient::SetAssignedSite method, in Configuration Manager, sets the client's assigned site.

[IDL]
HRESULT SetAssignedSite(
      BSTR sSiteCode, 
      long uFlags
);

Parameters

  • sSiteCode
    Data type: BSTR

    Qualifiers: [in]

    Site code to which the client is being assigned.

  • uFlags
    Data type: long

    Qualifiers: [in, optional, defaultvalue(0)]

    Flags indicating optional site information. Possible values are listed below. The default value is SMS_CLIENT_NOVERIFY. Use SMS_CLIENT_VERIFYSITECODE if the specified site code must be verified against its default management point.

    0

    SMS_CLIENT_NOVERIFY

    0x1

    SMS_CLIENT_VERIFYSITECODE

    0x2

    SMS_CLIENT_VERIFYMANAGEMENTPOINT

Return Value

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

  • S_OK
    The method succeeded.
  • SMSCLIENT_E_INVALIDSITECODE
    The site code was invalid.
  • WBEM_E_xxxx
    An error occurred updating Windows Management Instrumentation (WMI).

Remarks

Local administrator privileges are required to call this method.

Requirements

smsclient.dll

Runtime Requirements

For more information, see Configuration Manager Client Runtime Requirements.

Development Requirements

For more information, see Configuration Manager Client Development Requirements.

See Also

Concepts

ISmsClient Client COM Automation Interface
Configuration Manager Client Configuration