display the details of user after successful login
I have created a system for computer repair shop in C#.i created form for the user to login and when they successfully login, the data of the user (full name,address,etc )who had logged in will be displayed to another form . The problem here is when the user successfully logged in how can i display the data to another form? please give me code.
Wim SturkenboomPosted Oct 21, 2014, 12:10 AM
In both cases, run a query like
select * from yourusertable where name='username' and password='userpassword'
Check if you get rows back; if 0 rows, failed login, if 1 row successful login, if more rows you have a problem
For webbased, store the userid in a session variable, redirect to next page, query database based on userid in session variable and display data.
For desktop, store the userid in a global variable, open next form, query database based on userid in global variable and display data.
Other question is if this is windows based, linux based or ....
Chathurika PalliyagurugePosted Oct 20, 2014, 11:34 PM
Gopi ChandPosted Oct 15, 2014, 3:55 AM
Munesh SharmaPosted Oct 15, 2014, 2:36 AM
http://www.codeproject.com/Questions/550801/howpluswouldplusiplusshowplusmyplususerplusnameplu