hello,
When i login, my username is on the top right of the page. I want to bring that username into my main content page, but it's keep saying object is not an instant object.
here is my code on the pageload.
Dim lblMessage As Label = (TryCast(Me.Parent.FindControl("LoginView1"), Label))
lblMessage.Text = Label84.Text
<LoggedInTemplate>
| Logged in as: <asp:LoginName ID="LoginName1" runat="server" login1="UserName"/>
| <asp:Label ID="DividerLabel4" runat="server" Visible="False"> | </asp:Label>
<asp:LoginStatus ID="LoginStatus1" runat="server" LogoutAction="RedirectToLoginPage" />
|
</LoggedInTemplate>
please help.
thank you.