Advertisement
Guest User

Untitled

a guest
Jan 28th, 2019
132
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. String sDEFAULTUSER = "CN1801K";
  2. String sDEFAULTPWD = "Pa$$w0rd";
  3.  
  4. String sLoginId = "";
  5. String sPassword = "";
  6.  
  7. sLoginId = txtuserlogin.Text;
  8. sPassword = txtuserpass.Text; // 22Jan19
  9.  
  10.  
  11.  
  12.  
  13. {
  14.  
  15. if (sLoginId == sDEFAULTUSER)
  16. {
  17. if(sPassword == sDEFAULTPWD)
  18. {
  19.  
  20. Response.Redirect("mainpage.aspx");
  21. }
  22.  
  23.  
  24.  
  25. }
  26. else
  27. {
  28. lblErrorLoginId.Text = "Invalid UserId! Pls try again!";
  29. lblErrorPassword.Text = "Wrong Password!";
  30.  
  31.  
  32. }
  33. }
  34. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement