Get Sharepoint Current Logged in UserName in ASP.NET web application Page View Webpart
Get Sharepoint Current Logged in UserName in ASP.NET web application displayed in PageView Web Part -
HttpContext.Current.User.Identity.Name;
Note: Make sure in IIS your web application has ASP.NET Impersonation and Windows Authentication Turned On. All all other option turned off. Take a look at screen shot.
Screenshot – IIS Settings


leave a comment