Bool LoadAccount (
LPCTSTR pszAccountName,
LPCTSTR pszSystem=NULL
) throw (... );
Bool LoadAccount (
Const SID * pSid,
LPCTSTR pszSystem=NULL
) throw (... );
pszAccountName
The account name.
pszSystem
The system name. This string can be The name of a remote computer. If This string is NULL, The local system is 2 home.
pSid
A pointer to A SID structure.
I want to check a domain user can log in on the machine, I should how to pass an argument to this function? Consult,
CodePudding user response:
Suppose I two computers, one Win7x64, a Win10x64, respectively, have joined the domain testdomain.com, but never log in to the server, to join the use with server administrator account to join the domain,At this time I call on Windows 7 LoadAccount into my domain server. An existing user name jia deng returns true,
And call on Win10 system LoadAccount introduced to the same user name jia. Deng returns false,
sid. LoadAccount (_T (" jia. Deng "));
What reason is this excuse me?