hyperlink with querystring based on value in textbox

  • Thread starter Thread starter Stephen Witter
  • Start date Start date
S

Stephen Witter

I have a hyperlink and I want the navigateURL to point to another web
form while passing a value of a textbox as a querystring:

<asp:hyperlink navigateURL="MyPage.aspx?ID=<%# MyTexBox.text %> etc..

I can't seem to figure out how to do this

Then in the other form it doesn't seem to like either of these

dim intID as integer=request.querystring("ID")

or

dim intID as integer=request.querystring["ID"]

I am fairly new to asp.net and woudl appreciate the help.
 
I resorted to the follwing in the page load event:

HyperLink1.NavigateUrl ="MyPage.aspx?ID=" & txtMyTextbox.text

although I think there is a better event to put this into due to the
fact that I have to submit the page twice to get it to work.
 
Back
Top