Login User Information

G

Guest

Dear Experts,

I am using the Login Control in ASP.NET 2.0 in my web application. I would
like to retrieve the login user login name. Can somebody give me some tips or
the code on getting the login user ID after login through the login control.

Many thanks in advance.

Regards,
SB
 
K

Ken Cox - Microsoft MVP

Do you mean using the LoginName control?


<asp:loginname id="LoginName1" runat="server" />
 
N

Newbie

Hi,

Assume your user has already successfully logged in, you can retrieve its
userid by: user.identity.name

HTH,
andy
 

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