Customizing message/behavior

Posted on 16th Feb 2014 by admin

Hi,I'm using the ASP.NET membership/authorization controls in my application. Some parts of my application are reserved for users who are in certain roles i.e. editor, writer, etc. I control this with web.config files for those folders. My question is how do I give users meaningful and customized feedback if they try to access an area that they're not authorized for. For example if a writer tries to access an area that is only reserved for editors, I'd like to tell them something like "This area is for editors only". How can I create this behavior?

Other forums