Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

I need to be able to have a user login and be redirected to different index pages based on their ID's

Posted on 2008-10-13
2
Medium Priority
?
150 Views
Last Modified: 2013-11-07
I have a login.aspx page developed. I need to figure out how to tie this to an Access 2003 database that stores the user id and passwords. If the id and pass are correct then redirect the user to a file location and index.aspx page. I am not sure if I need to have the folder and page file in the database or in the code behind. Any ideas and sample code you can provide me would be greatly appreciated. Here is the file structure I am using. In the () is the user id that I will need in the database to access this directory. Thanks for your time. And I don't want to use the membership tables if at all possible.

client folder
login.aspx
----- c1 folder (id_00001)
----- index.aspx

----- c2 folder (id_00002)
----- index.aspx
0
Comment
Question by:woodje
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 6

Accepted Solution

by:
pwrBall earned 2000 total points
ID: 22707037
It sounds like you need to create user roles for your site.  

You should have a table that contains user roles, and assign each user a specific role like 'admin' and 'user'

UserRole table:
userRoleID         userRoleName
1                        admin
2                        user
3                        poweruser


So you'd have to create a user role table in access and a new column in the user table for the role ID.

Based off of the role ID, that you should check during login, you would send the user to a specific hard coded directory.

This helps to:
http://www.codeproject.com/KB/aspnet/custom_authentication.aspx

The above link does not include accessing a database though.

I created a Login class which I call from the login page code behind to connect to the database with the passed in credentials that the user types in.  Only difference is that I used SQL Server 2000.
Based off of the users' role, I passed them to a different folder that they had access to.


0
 
LVL 83

Expert Comment

by:CodeCruiser
ID: 22711030
Explore the ASP.NET Routing and Dynamic Data. I thinks that has the answer to your question.
0

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In my previous two articles we discussed Binary Serialization (http://www.experts-exchange.com/A_4362.html) and XML Serialization (http://www.experts-exchange.com/A_4425.html). In this article we will try to know more about SOAP (Simple Object Acces…
A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question