Click here to Skip to main content
15,891,431 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,
I m developing a college site in that i have register detail about the user after that the user login and they see their detail and others details which i shows in grid view... If the user want to change their detail in grid view how to do. the particular user detail only to change who login. Other person should be edit in the gridview.

Ex: If i login means it shows the gridview and i want to edit my details i should not able to edit other details i can see only the other detail i should not edit their details in gridview how can i do this in gridview using C#.
I need code for this can anyone help.
Posted
Updated 4-Jul-11 1:18am
v3
Comments
Wayne Gaylard 4-Jul-11 7:27am    
You need to ask yourself whether a user should be able to see the details of other users. You should create a page/window specifically for editing a users own details.
Syed Salman Raza Zaidi 4-Jul-11 17:01pm    
For this you should provide a Column in Database table and at time of login set it true and at run time check for that value if it is true then only allow editing for that user whose value = true you can also use login time with it to avoid any conflicts

you can check login credential it the page load 
if the authentiction is correct then you can set hide or show the column which have edit button
 
Share this answer
 
do one thing

every user have unique identity right.
then after the user clicks on edit then check the logged in user identity is equal to the record he going to modify..
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900