Sniff your Active Directory username like so:
public static string userName = WindowsIdentity.GetCurrent().Name;
Use this namespace:
using System.Security.Principal;
No comments:
Post a Comment