How do I secure a page under root with Asp.Net Idenity in WebForms working on Aspneidentity 2

0 votes
asked Feb 4, 2016 by strangemil (2,540 points)
5, Identity 2, WebFormsI use Visual Studio 2013 WebForms project template to generate project.

4 Answers

0 votes
answered Mar 28, 2016 by lewelling (480 points)
selected Mar 29, 2016 by fub904
Best answer
This is an old answer that I posted some years ago
This matches Asp.NET Identity with Webforms and Oracle I don't think it should
commented Mar 29, 2016 by fub904 (2,130 points)
IsInRole(roleName) with a call to the Roles
commented Mar 30, 2016 by Unlikelyhol (720 points)
You are not a member of the Supervisors or Administrators roles
–1 vote
answered Mar 18, 2016 by Emmanu (270 points)

NET page to execute the desired method.
Test this page through a browser.
First visit the page as an anonymous user.
Take a look at Role-Based Authorization (C#) | The ASP.NET Site
commented Mar 20, 2016 by emmerson7149 (610 points)
IsUserInRole(roleName) method
0 votes
answered Mar 19, 2016 by Shona (840 points)
I ran into this problem this morning too. See for more info on that
0 votes
answered Mar 31, 2016 by tvg_356 (1,900 points)
IsInRole(roleName) involves just one trip to the role store whereas Roles
commented Mar 31, 2016 by Ynhvagas (470 points)
Simply click the Edit button, make your changes, and then click Update
commented Apr 2, 2016 by natalia (560 points)
Remember: With great power comes great responsibility

What is Geekub?

Q&A site for professional and enthusiast programmers, software developers and other technical users. With your help, we hope to work together to build a library of detailed answers to just about any question that is related to programming!