[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Role based Authorization (User.IsInRole("Administrator"))

Posted on 2008-11-07
1
Medium Priority
?
351 Views
Last Modified: 2012-05-05
I have recently inherited an existing system and I need to access the User.IsInRole function from with the Authenticate method -- is this possible.

Once the Authenticate method is executed User object is always available but is *not* populated when one tries to access it in the Authenticate method itself.

The application uses the in built login controls. the environment is .net 2.0.

thanks

0
Comment
Question by:sanagarwl
1 Comment
 
LVL 8

Accepted Solution

by:
tiagosalgado earned 2000 total points
ID: 22909473
Instead of User.IsInRole, use Roles.IsUserInRole("username","Your Role")
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

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

You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Suggested Courses
Course of the Month18 days, 18 hours left to enroll

834 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