Problem usingSystem.Threading.Thread.CurrentPrincipal.Identity.Name

L

Lakshman Maruri

We have migrated our application(VB.NET) from .NET 1.1 to 2.0. When accessing the identity of the user, using "System.Threading.Thread.CurrentPrincipal.Identity.Name", it returns me nothing in .NET 2.0 where as code works fine in 1.1.

If I use "System.Threading.Thread.CurrentPrincipal = New WindowsPrincipal(WindowsIdentity.GetCurrent())" and now get the identity, it gives me "My Laptop domain/user name" insted of "my corporate domain/username".

Can somebody help me with this resolved.

EggHeadCafe - .NET Developer Portal of Choice
http://www.eggheadcafe.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top