Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I include 2 values in a redirect? 2

Status
Not open for further replies.

streborr

IS-IT--Management
Jan 16, 2002
98
I'm trying to send a user to a page that will show information about specific companies in a specific region.

response.redirect("region.asp?user_Company=" & rsADO("user_company") & user_region=" & rsADO("user_region"))

This code produces: Expected")"

How do I include 2 values in a redirect?

Thanks for any help!

 
You forgot some quotes. Look below

response.redirect("region.asp?user_Company=" & rsADO("user_company") & " user_region=" & rsADO("user_region")&")
 
and you need to strip the space from between your value pairs:

response.redirect("region.asp?user_Company=" & rsADO("user_company") & "user_region=" & rsADO("user_region")&")
 
oops!
you need an ampersand where that space was.....

response.redirect("region.asp?user_Company=" & rsADO("user_company") & "&user_region=" & rsADO("user_region")&")
 
here are the suggeseted changes:

response.redirect("region.asp?user_Company=" & rsADO("user_company") & "&user_region=" & rsADO("user_region")&")

here's the new error:

Unterminated string constant
 
You need another " at the end before the last ) as shown below.

response.redirect("region.asp?user_Company=" & rsADO("user_company") & "&user_region=" & rsADO("user_region")&"")
 
remove the last &"

response.redirect("region.asp?user_Company=" & rsADO("user_company") & "&user_region=" & rsADO("user_region"))
 
Thanks, that did it!

(the ink on my " key is wearing thin.)

Rick
 
(the ink on my " key is wearing thin.)

-- that's what the 'any' key is for - it's multipurpose!

:p
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top