how i can retrive the username from database based on the username and password only to make a welcome at the first page?
new SE
0
Junior Poster in Training
Recommended Answers
Jump to PostPerhaps I'm misreading this but...
It sounds to me like you're passing the UN/PW to the DB to check if they're valid for a login and want to then get the UN back from the DB for the purpose of a welcome page.
This may sound silly but... …
Jump to PostJust Create a session put the user name in it access in your master page and use it where ever you want to use that's all.
egSession["FirstName"] = FirstNameTextBox.Text;
to access
String str=Session["FirstName"].ToString();
that's all you need to do.
Jump to PostFirst, are you using one form/page to login and a separate form/page for your welcome? If so, you would need to look at various methods of passing a variable from the login page to the secondary page.
One such method is to pass the variable as a part of …
All 11 Replies
Lusiphur
185
Practically a Posting Shark
Team Colleague
Featured Poster
new SE
0
Junior Poster in Training
new SE
0
Junior Poster in Training
ans2007kumar
0
Light Poster
Lusiphur
185
Practically a Posting Shark
Team Colleague
Featured Poster
new SE
0
Junior Poster in Training
new SE
0
Junior Poster in Training
new SE
0
Junior Poster in Training
mono_jit23
1
Junior Poster in Training
mono_jit23
1
Junior Poster in Training
new SE
0
Junior Poster in Training
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.