' Checking if an user has logged in
----------------------------------------------------------
Redirect Page on Anonymous Entry
The LoginView control can be used to check if an user has logged in. The control displays one of
<loggedintemplate>
</loggedintemplate></asp:loginview></loggedintemplate><p>Welcome back! </p>
<anonymoustemplate>
You are not logged in <a href="http://www2.blogger.com/Login.aspx">Login</a>
</anonymoustemplate></span></blockquote><span style="color: rgb(51, 102, 255);">
</span><loggedintemplate><asp:loginview id="LoginView1" runat="server">
<loggedintemplate>
</loggedintemplate></asp:loginview></loggedintemplate><p>Welcome back! </p>
<anonymoustemplate>
You are not logged in <a href="http://www2.blogger.com/Login.aspx">Login</a>
</anonymoustemplate>
The LoginView control also includes events for ViewChanging and ViewChanged, which allow you to write handlers for when the user logs in and changes status.
LoginView control, Check Login Status, Redirect Page on Login