IFPCServer3::JoinWorkgroup method
Applies to: desktop apps only
The JoinWorkgroup method joins the server to the specified workgroup using the specified user name and password to detach it from the current domain, and restarts the computer to apply the change if requested
Syntax
HRESULT JoinWorkgroup(
[in] BSTR Workgroup,
[in] String Workgroup,
[in] BSTR CurrentDomainUserName,
[in] String CurrentDomainUserName,
[in] BSTR CurrentDomainUserPassword,
[in] String CurrentDomainUserPassword,
[in, optional] VARIANT_BOOL RestartNow,
[in, optional] Boolean RestartNow
);
FPCServer.JoinWorkgroup( _
ByVal Workgroup As BSTR, _
ByVal Workgroup As String, _
ByVal CurrentDomainUserName As BSTR, _
ByVal CurrentDomainUserName As String, _
ByVal CurrentDomainUserPassword As BSTR, _
ByVal CurrentDomainUserPassword As String, _
[ ByVal RestartNow As VARIANT_BOOL ], _
[ ByVal RestartNow As Boolean ] _
)
Parameters
Workgroup [in]
C++ Required. BSTR that specifies the workgroup to which the server will be joined.
VB Required. String that specifies the workgroup to which the server will be joined.
CurrentDomainUserName [in]
C++ Required. BSTR that specifies the user name in the current domain.
VB Required. String that specifies the user name in the current domain.
CurrentDomainUserPassword [in]
C++ Required. BSTR that specifies the user password in the current domain.
VB Required. String the specifies the user password in the current domain.
RestartNow [in, optional]
C++ Boolean value that indicates whether to restart the computer after the method has completed.
VB Boolean value that indicates whether to restart the computer after the method has completed.
Return value
C++
This method returns S_OK if the call is successful; otherwise, it returns an error code.
VB
If the call is unsuccessful, an error is raised that can be intercepted by using an error handler.
Remarks
The computer must be restarted to apply the change.
Requirements
Minimum supported client |
Windows Vista |
Minimum supported server |
Windows Server 2008 R2, Windows Server 2008 with SP2 (64-bit only) |
Version |
Forefront Threat Management Gateway (TMG) 2010 |
IDL |
Msfpccom.idl |
DLL |
Msfpccom.dll |
See also
Build date: 7/12/2010