What I am trying to do is....
I want to switch to Page2.aspx using a response.redirect but I want
Page2.aspx to display in a New Browser Window. If I simply execute
response.redirect(page2.aspx) it will display in the same browser window.
If I have a hyperlink added at design time and specify '_new' in the target
property it will pop up a new window when that hyperlink is clicked by the
user. But if I try to execute that hyperlink from code by doing
response.redirect(myHyperlink.NavigateURL) it simply uses that string and
doesn't really execute the hyperlink in the web page (that has Target='_new'
in it).
G
"John Hann" <jovinhan@SPAM_FREEyahoo.com> wrote in message
news:ez**************@TK2MSFTNGP12.phx.gbl...
G. Dean Blake wrote:
"it" means the hyperlink control on my page(which has target='_new'),
not just a url.
"John Hann" <jovinhan@SPAM_FREEyahoo.com> wrote in message
news:JZ********************@comcast.com...
G. Dean Blake wrote:
I have a hyperlink on my aspx page added at dev time. Is there a way
toexecute it from code?
Thanks,
G
Response.Redirect( <yourLinkHere> );
In that case, I'm not quite sure what you're trying to accomplish.
"_new" does not have a special meaning as a value for the Target
property, so I doubt that will affect the behavior of your HyperLink.
And you're trying to "execute" it from code, does that mean redirect the
browser to the NavigateURL of the HyperLink? If you want to do that, try
this
Reponse.Redirect(yourHyperLink.NavigateURL);
If that's not what you intend to do, please be more specific.
- John