ASP.NET LoginName control problems?

Joanzn

New member
I'm trying to get the user name of the person logged in when they're logged in and says guest when they're not.. heres the code on the masterpage:
<asp:LoginView ID="LoginView3" runat="server">
<AnonymousTemplate>Welcome to Some.Com Guest</AnonymousTemplate>
<LoggedInTemplate>
<asp:LoginName id="LoginName1" runat="Server" FormatString="Some.Com Welcomes You Back,{0}"></asp:LoginName>
</LoggedInTemplate>..
the problem I keep having with this code is that I get the return of the primaryKey from the DB.
while looking at it in VS2010 design mode on the anonymous it says "guest" and from the logged in it says [UserName] and that is the name of the DB field as well..
Any Help?
Any thoughts?
 
Back
Top