NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

WindowsPrincipal Constructor

Constructs a WindowsPrincipal object from a WindowsIdentity object.

[Visual Basic]
Public Sub New( _
   ByVal ntIdentity As WindowsIdentity _
)
[C#]
public WindowsPrincipal(
   WindowsIdentity ntIdentity
);
[C++]
public: WindowsPrincipal(
   WindowsIdentity* ntIdentity
);
[JScript]
public function WindowsPrincipal(
   ntIdentity : WindowsIdentity
);

Parameters

ntIdentity
A WindowsIdentity object

Example [C#]

[C#]

WindowsIdentity wi = WindowsIdentity.GetCurrent();
WindowsPrincipal wp = new WindowsPrincipal(wi);

bob

See Also

WindowsPrincipal Class | WindowsPrincipal Members | System.Security.Principal Namespace