Solved

How can I update a URL returned in a query?

Posted on 2008-10-20
3
269 Views
Last Modified: 2012-05-05
Using ASP/VBscript with an Access data base. One of the items returned in the record set is defined as text and contains this URL value:

http://www.signaturetravelnetwork.com/product/cruise/ship_builder/overview.cfm?product_id=69&sup_id=26&utp=consumer&agency_id=__agency_key__&type=consumer

Before I can use this URL on my web page I need to replace '__agency_key__' with the value 826. How do I manage this?
0
Comment
Question by:travelq13
  • 2
3 Comments
 
LVL 16

Expert Comment

by:brad2575
ID: 22756621
Replace(URLSTring, "__agency_key__", "826")

0
 

Author Comment

by:travelq13
ID: 22759697
I am not really certain how to use this with a value returned in the recordset.
0
 
LVL 16

Accepted Solution

by:
brad2575 earned 250 total points
ID: 22759836
wherever/however you are displaying this on the screen you would use this.

So if you have

Response.write(rs("URLValue"))

You woudl replace it with this:

Response.write(Replace(rs("URLValue"), "__agency_key__", "826")
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

815 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now