954,518 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

How to create a Login scheme to allow a user to view individual information

Beginning C# programmer here. I have had lots of problems finding online a tutorial or help-me thread where someone explains how to create the specific type of user profile database I need.

I need to use SQL and C#.NET to create a profile/role for each specific user on my website. Every single user will have private information that only he/she should be able to view.

All tutorials I have found so far only create roles such as admin, member and guest. Does anyone know how to do this? If I could use the built in login tools that .Net offers, that would be great.

Thanks in advance!

Wheater
Newbie Poster
1 post since Jan 2012
Reputation Points: 10
Solved Threads: 0
 

You can simply save the user with each role they have. The role would be another column in the log in table. Functions that have restricted access can check the assigned role. I think you were looking at how to give a user access to a database table which isn't what you need.
You mention you need to "create a profile/role for each specific user on my website". That makes it sound like every user will have a different role. If each user's role will be different why bother with roles anyway? Their user login credentials will set them apart from everyone else.

hericles
Practically a Posting Shark
823 posts since Nov 2007
Reputation Points: 136
Solved Threads: 167
 

Wheater,

Do you wish to use your own database for this or the built in ASP.Net database? As this can very easily be done using the built in one however I've had issues in the past trying to then link the ASP.Net DB to a custom one for the other details.

I have also done the login using my own DB and also managed to restrict access to pages using code on the master page but this was not so easy, all depends on what other functionality your database has.

MikeyIsMe
Junior Poster
142 posts since Nov 2010
Reputation Points: 32
Solved Threads: 15
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: