Response Redirect variables

Results 1 to 2 of 2

Thread: Response Redirect variables

  1. #1
    Aimskee Guest

    Default Response Redirect variables

    What is the correct syntax to pass more than 1 variable with Response.Redirect to a third page, where the first is the data entry form, the second is the redirect page and the third page is a preview page, while a fourth page will put the data in an Access table? I am new to this and I must be using the wrong syntax. I seem to lose the variables by the third page, so I know I have to pass them somehow. THe reason I have a second page is because I have 18 if endif statements depending on which asp the user should be redirected to next. So how do I use session or whatever; I need an example w/correct syntax, as that seems to be at least part of my problem. Thanks.

  2. #2
    Join Date
    Dec 1969
    Posts
    2,849

    Default RE: Response Redirect variables

    Well, each name/value in the querystring needs to be separated by an ampersand (&). So, if you want to pass three variables:<BR><BR>Response.Redirect "/somepage.asp?var1=value1&var2=value2&var3=value3"< BR><BR>Since the value1 through valueN&#039s are needing to be read using the Request object, your actual statement would look like:<BR><BR>Response.Redirect "/somepage.asp?var1=" & Request("var1") & "&var2=" & Request("var2") & "&var3=" & Request("var3")<BR><BR>If you are passing the same set of data between all three pages, you can just append the existing querystring onto the Response.Redirect like so:<BR><BR>Response.Redirect "/somefile.asp?" & Request.QueryString<BR><BR>Does this answer your question(s)? If not, let me know, and we&#039ll continue this thread. :-)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •