hi,
In asp.net 3.5 using vb i would like to go to another page in my application when the user clicks a button. what is the command for doing this?
Thank you
hi,
In asp.net 3.5 using vb i would like to go to another page in my application when the user clicks a button. what is the command for doing this?
Thank you
As TheTXI mentioned, Response.Redirect
will work just fine.
However, your button click code won't run until late in the page life cycle. Your server may have to do quite a bit of extra or unnecessary work first. If this is the only thing you are doing, just wrap the button in an anchor tag:
<a href="url"><asp:button .../></a>
server.Transfer("url",true) is much better to use because it hides the variables you want to pass if there are any.