ドメイン DomainA のユーザー User001 で、パスワード Pass001 でログインしています。
私はこのコードを使用します
//var principalContext = new PrincipalContext(
//ContextType.Domain,
//"DomainA",
//"User001",
//"Pass001");
var principalContext = new PrincipalContext(
ContextType.Domain,
domain,
userName,
password);
var userPrincipal = new UserPrincipal(principalContext);
そしてuserPrincipal
常に NULL です。
修正方法は?