asp.net - redirect a user based on Rolegroup -
I have a very easy way of calling on page load,
Identify the protected sub (if user.Identity.IsAuthenticated) then Else Response.Redirect ("login.aspx") end if end sub what I want to do is throw a redirect The role is a part of the user on the group, so if they have been certified, but "admin" is not part of the user group, Redirecting to a different page .... Some such as
protected sub-identities () if the user is Identity.IsAuthenticatedIf user. Indentia. Initial Group ("Admin") Response.Redirect ("AdministratorDefault .aspx ") End if other feedback. Redirect ("login.aspx") End & End End Is such a thing possible? I can not find any answer.
if (User.IsInRole ("Administrator") ... end if
Comments
Post a Comment