Response.Redirect can it open a new window ???

  • Thread starter Thread starter ODB
  • Start date Start date
O

ODB

Okay what i need is to open af new browser windows with some link in, but i
can't get the Response.Redirect to open af new window, and when i redirect
to a new page in the same window and then hit back, i have some olde
invalid data in my window. and i realy need to open af new browser ?

Thanks ODB
 
Any Response operation always goes back to the same window unless you
specify a target clause in the link that got you to the current request.
IOW, the referring link determines how the current link will be opened.

If you really need to do this you can redriect to a page that has some
JavaScript on it and opens a new window and loads the content into that.

+++ Rick ---

--

Rick Strahl
West Wind Technologies
http://www.west-wind.com/
http://www.west-wind.com/blog/
 
Here is an example of how it can be done in your code so that you can
control it.

dim strurl as string = "http://www.yahoo.com"

dim strCommand as string = "vlarge1=window.open('" & strurl &
"','vlarge','resizable=no,scrollbars=no,status=no,toolbar=no,height=450,widt
h=575,left=150,top=100');vlarge1.focus();" & vbCrLf

dim strCommand as string = "window.open('" & strurl & "','','');" & vbCrLf

response.write("<script>" & vbCrLf)
response.write(strCommand & vbCrLf)
response.write("<" & chr(47) & "script>")
response.redirect(strUrl)
 
Sorry my post should read

Here is an example of how it can be done in your code so that you can
control it.

dim strurl as string = "http://www.yahoo.com"

dim strCommand as string = "vlarge1=window.open('" & strurl &
"','vlarge','resizable=no,scrollbars=no,status=no,toolbar=no,height=450,widt
h=575,left=150,top=100');vlarge1.focus();" & vbCrLf

or you can use if you don't want to size it
dim strCommand as string = "window.open('" & strurl & "','','');" & vbCrLf

response.write("<script>" & vbCrLf)
response.write(strCommand & vbCrLf)
response.write("<" & chr(47) & "script>")

don't put this line in
'response.redirect(strUrl)
 
Back
Top