passing value to redirect

Discussion in 'ASP .Net' started by Laura K, Nov 22, 2004.

  1. Laura K

    Laura K Guest

    I know this is basic but I just can not get my head around it.

    I would like to take a querystring and from that querystring redirect the
    user to a specific page. I set up a simple test and I am doing something
    wrong. Kinda a newbie here so here it goes.

    I have tested the querystring by passing it to a label to make sure it is
    correct and the querystring that I have been testing this with is 7jackets.
    The redirect takes me to the case else option (the index page).

    I have tried this with if/than and now with case....

    Ideas?

    Here is the code.

    <script runat="server">

    sub page_load()
    dim strQueryvalue as string

    strQueryValue = (Request.QueryString("strCssPath")) &
    (Request.QueryString("strSubCategory"))


    Select case strQueryValue

    Case "7jackets"
    response.redirect("redirection/pants.aspx")
    case "5boots"
    response.redirect("redirection/shoes.aspx")
    case else
    response.redirect("index.aspx")

    end select

    end sub


    </script>
    Laura K, Nov 22, 2004
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Anne
    Replies:
    7
    Views:
    11,872
  2. =?Utf-8?B?VHJveQ==?=

    Response.redirect does not redirect from .aspx page

    =?Utf-8?B?VHJveQ==?=, Oct 18, 2004, in forum: ASP .Net
    Replies:
    3
    Views:
    5,206
    Srowe1975
    Oct 15, 2008
  3. Victor Bazarov
    Replies:
    25
    Views:
    838
    E. Robert Tisdale
    Mar 23, 2005
  4. Sal
    Replies:
    1
    Views:
    359
  5. Ron Howard
    Replies:
    2
    Views:
    499
    Ron Howard
    Aug 11, 2004
Loading...

Share This Page