hi ,
I have a problem with displaying the user profile who is login.
I am created user using createuser wizard of asp .net.
When click on countinu button it goes to somemoredetails.aspx form
I just want to edit the profile details on the somemoredetails.aspx of user who is login. I was doing this using a session variable
On master page I have a login form so I am just clicking on it and write the code in this is…
Protected Sub Login1_Authenticate(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.AuthenticateEventArgs)

If Login1.UserName <> "" Then
Session("UserName") = Login1.UserName
End If
End Sub

And after that I have set the select query in sqldatasource on the formview
Select …..
Form tname
Where(UserName=@UserName) .

And doing defineparameter process with session variable “UserName”
And its working .it shows formview of the login User only.
But problem is it dose not shows user name on every page, so I just changes login code with loginview such as...

<asp:LoginView ID="LoginView1" runat="server" >
<LoggedInTemplate >
<asp:LoginName ID="LoginName1" runat="server" Font-Bold="True" ForeColor="Crimson"
FormatString="Wel-come! {0}" Style="z-index: 102; left: 89px; position: absolute;
top: 21px" Width="168px" />
<asp:LinkButton ID="LinkButton2" runat="server" PostBackUrl="~/changepass.aspx" Style="z-index: 100;
left: 5px; position: absolute; top: 0px">ChangePassword</asp:LinkButton>

<AnonymousTemplate >
<asp:Login ID="Login1" runat="server" BackColor="#F7F6F3" BorderColor="#E6E2D8" BorderPadding="4"
BorderStyle="Solid" BorderWidth="1px" CreateUserText="NewUserSignUp" CreateUserUrl="~/createuser.aspx"
Font-Bold="False" Font-Names="Verdana" Font-Size="0.8em" ForeColor="#333333"
Height="157px" PasswordRecoveryText="Forgot Password" PasswordRecoveryUrl="~/newPass.aspx"
Style="z-index: 100; left: 2px; position: absolute; top: 3px" Width="235px" DestinationPageUrl="~/Accmerhome.aspx" >
<TitleTextStyle BackColor="#5D7B9D" Font-Bold="True" Font-Size="0.9em" ForeColor="White" />
<InstructionTextStyle Font-Italic="True" ForeColor="Black" />
<TextBoxStyle Font-Size="0.8em" />
<LoginButtonStyle BackColor="#FFFBFF" BorderColor="#CCCCCC" BorderStyle="Solid" BorderWidth="1px"
Font-Names="Verdana" Font-Size="0.8em" ForeColor="#284775" />

So it shows the loginName and status of login but when click on the login form..
it dose not create session variable of login it shows error like..
If Login1.UserName <> "" Then
Session("UserName") = Login1.UserName (error on red letter)
It diplay error like”login1 is not declare”
So just tell me how will I solve my problem or any other method for displaying the formview of the user who is login only becoze I want to update my records when I am ckicking on edit profile