Click here to Skip to main content
15,889,876 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
How to make privilege form for the user.
like this.
For Example;
A user(user1) can not open the city form after login into the main page.


Anyone Can Help me.
Posted
Comments
ZurdoDev 6-Feb-13 8:51am    
You mean they can't open the form UNTIL after login? Use FormsAuthentication.

1 solution

In web.config, you can mention which all users can access your city form.Based on this it will be restricted

Try this
C#
<location path="Admin.aspx">
<system.web>
<authorization>
<allow users="user1" />
<deny users="*" />
</authorization>
</system.web>
</location>
<location path="User.aspx">
<system.web>
<authorization>
<allow users="user1" />
<allow users="user2" />
<deny users="*" />
</authorization>
</system.web>
</location>
 
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