Guest User

Untitled

a guest
Aug 19th, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.35 KB | None | 0 0
  1. Find control in loginview
  2. Login lg = (Login)LoginView1.FindControl("Login1");
  3. TextBox tb = (TextBox)lg.FindControl("UserName");
  4.  
  5. Label2.Text = tb.Text;
  6.  
  7. if (!HttpContext.Current.User.Identity.IsAuthenticated) {
  8. Login lg = (WebControls.Login)LoginView1.FindControl("Login1");
  9. TextBox tb = (TextBox)lg.FindControl("UserName");
  10. Label2.Text = tb.Text;
  11. }
Add Comment
Please, Sign In to add comment