Hi.
I have a project,where it will display the username of the current logged in user (loginname control) after user login.
In that project,i have own custom data which allows users to enter some information that will be stored in my custom database.
Along with the other information i also want the login name control to store the content ie the User's name, to my custom database.
Any ideas guys?
Login Name control
Page 1 of 13 Replies - 2477 Views - Last Post: 02 September 2010 - 05:08 AM
Replies To: Login Name control
#2
Re: Login Name control
Posted 01 September 2010 - 04:36 AM
You can't get the username from the LoginUser control. You have to use the Membership class.
MembershipUser user = Membership.GetUser(); string loggedInUserName = user.UserName;
#3
Re: Login Name control
Posted 01 September 2010 - 05:44 PM
Ok,where do i apply this code?i'm using master page.
and how it works?
and how it works?
#4
Re: Login Name control
Posted 02 September 2010 - 05:08 AM
You apply it anywhere where you want to get the username of the logged in user.
Page 1 of 1

New Topic/Question
Reply



MultiQuote


|