IsInRole problem

G

Guest

Hi

I have a strange problem with my asp.net application. I am using the
following code to see if a user is in a windows group:

if(!System.Threading.Thread.CurrentPrincipal.IsInRole(System.Configuration.ConfigurationSettings.AppSettings.Ge(@"WindowsGroupForVaspUsers")))

I also have this row in my config file:

<add key="WindowsGroupForVaspUsers" value="adcsth1800\VASP"/>

The strange thing is that this works fine in one application but in another
application (I run locally on the same computer) I need to use slash instead
on back slash for the code to work. I need to change the config file to this:

<add key="WindowsGroupForVaspUsers" value="adcsth1800/VASP"/>

Why???

Thanks
Julia
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

problem with .IsInRole 0
isInRole Problem 5
IsInRole problem? 2
isInRole 0
Esp8266 Code problem 0
Problem 0
IsInRole problem 3
IsInRole still returns false! 3

Members online

No members online now.

Forum statistics

Threads
473,763
Messages
2,569,562
Members
45,038
Latest member
OrderProperKetocapsules

Latest Threads

Top