Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Apr 30, 2012 09:28 PM|LINK
I used and i made my Login system so, there were rolls i made..
Concentrate the Scenario:
its my Login Table
UserName ---- Password ---- CampusCode
MyName ---- 123PW ------- NK
On login page I Coded like this
str = "select * from login where Username =@username and Password =@password";
cmd = new SqlCommand(str, con);
sdr = cmd.ExecuteReader();
Session["Campus"] = sdr["CampusCode"].ToString(); // then Responce.reditect to another page then
So I took value of Campus By Session now , on 2nd Page On top right i put the Label and Put the Session value of Campus.
then on page load i Programed like
if (Label.Text = "NK")
panel1.visible = false;
else if ( Label.Text = "2nd Campus etc")
Panel2.Visible = true;
More over you will have to work hard for it. but you can do better in asp.net Membership system.