Quantcast
Channel: Security
Viewing all articles
Browse latest Browse all 4737

how can I "Response.Redirect" to a new webform based on members of a server group or if the user is within a SQL table

$
0
0

I have an asp.net dynamic data website and I want to have a web form which will direct a user to a Wrobform based on if they work in India vs. US.  I have a group set up on the server called "India" which contains all the India users and I want the web form to have a response.redirect and point people to the India landing page if they are a member of that group, and to the US landing page if they are not part of that group.

Example:

    Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)

If Roles.IsUserInRole(User.Identity.Name, "mydomain\India")

      Response.Redirect("http://India_Landing.aspx")

Else Response.Redirect("http://US_Landing.aspx")

        End If

    End Sub

If this isn't achieveable with the server group, I can do it based on a field in a sql table that is linked to the asp.net website.  Just need to get this complete!  THANK YOU


Viewing all articles
Browse latest Browse all 4737

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>