I have been making some progress on this but still have some issues to resolve.
Hopefully, this one won’t be that hard.
I have this:
For Each item In Request.QueryString("doc").Split(","c)
sb.Append("http://default.html?k=")
sb.Append(item)
sb.Append("&p=2&o=m</p>")
Next
When I test this code:
Response.Write(sb.ToString())
I get:
http://default.html?k=122&p=2&o=m
http://default.html?k=123&p=2&o=m
That’s exactly what we are looking for
When we assign it to a variable like:
Dim linkList As String = sb.ToString()
However, when I loop through linkList
and write it to the screen, it is spitting out only the letter h.
Any ideas what I am doing wrong and how to fix it if possible?
Dim link As String
For Each link I linkList
'let me know if I am still getting the links
response.write link
'we will save all the links later
Next
As always, thanks a lot for your help
You can not loop through a string and get another string (note: linkList is a String –
Dim linkList As String = sb.ToString()). That’s why you get the h it’s trying to pick the Chars in the string. Place the strings in an array then loop through the array. Try this: