I have a function that looks like this:
Private Sub displayData(title As String, cost As String, asin As String)
cdCheckList.Items.Add(title + "/" + cost + "/" + asin)
End Sub
I want to make the entire string (title + “/” + cost + “/” + asin) a hyperlink to another page called SearchDisplay.aspx.
EDIT: I need to send the the values of title, cost, and asin to the other page as well.
Not totally sure how this can be done. Can someone help me out?
I don’t have Visual Studio to hand but could you try:
or using
String.Formatwould look nicer and easier to read:Updated to answer OP’s re-phrased question:
You should always encode URL query string parameters. You should look at using Microsoft’s AntiXss library instead of the HttpUtility class. You can find out more information on the AntiXss library here.