473,624 Members | 2,534 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

how to open new window and response.write to it

Hi,

Anyone know how to open a New Browser window and then "response.write " to
the new window. I know how to open a new window, but then targeting
response.write at it is a mystery.

I need to keep the original window open as well as the new one.

Can anyone help?
Nov 19 '05 #1
11 5177
Hi Josh,

Opening a new window is done using JavaScript. It includes providing the URL
of the resource (ASP.Net document) that will be loaded into the window. A
Response is a Response to a Request. The Request is for a given URL.
Therefore, the ASP.Net document loaded into the new window will Respond to
the Request for the URL of the ASP.Net document loaded into the new window.

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
What You Seek Is What You Get.

"Josh" <s@a.com> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
Hi,

Anyone know how to open a New Browser window and then "response.write " to
the new window. I know how to open a new window, but then targeting
response.write at it is a mystery.

I need to keep the original window open as well as the new one.

Can anyone help?

Nov 19 '05 #2
Set

<base target="_self">

in the <head> section of the page that you show in the new window.

Eliyahu

"Josh" <s@a.com> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
Hi,

Anyone know how to open a New Browser window and then "response.write " to
the new window. I know how to open a new window, but then targeting
response.write at it is a mystery.

I need to keep the original window open as well as the new one.

Can anyone help?

Nov 19 '05 #3
Where do you need to effect resopnse.write? New window, or old one?

"Josh" wrote:
Hi,

Anyone know how to open a New Browser window and then "response.write " to
the new window. I know how to open a new window, but then targeting
response.write at it is a mystery.

I need to keep the original window open as well as the new one.

Can anyone help?

Nov 19 '05 #4
I've not made myself clear.

I can open a new window with javascript no problem. But then I dont want to
pass a url to the window I need to write to it using the Response stream.

The current system cause an IO nightmare because it writes an HTML page to
disk then opens a window pointing to that page.

I need to get the same effect without writting to disk.

Thanks
Nov 19 '05 #5
"Josh" <s@a.com> wrote in message
news:%2******** *******@TK2MSFT NGP12.phx.gbl.. .
But then I dont want to pass a url to the window


I don't think you've got much choice...

Why not have a blank page that you can open as and when required, and write
to that instead...?
Nov 19 '05 #6
I could be be mistaken, but I think that's exactly what he's trying to
do...open a new window, write a respose to it. LOL

"Mark Rae" <ma**@mark-N-O-S-P-A-M-rae.co.uk> wrote in message
news:ud******** ******@TK2MSFTN GP15.phx.gbl...
"Josh" <s@a.com> wrote in message
news:%2******** *******@TK2MSFT NGP12.phx.gbl.. .
But then I dont want to pass a url to the window
I don't think you've got much choice...

Why not have a blank page that you can open as and when required, and

write to that instead...?

Nov 19 '05 #7
new window
Nov 19 '05 #8
Oh, I understood you fine. Perhaps I didn't make MY self clear. But I don't
know how to make it any clearer.

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
What You Seek Is What You Get.

"Josh" <s@a.com> wrote in message
news:%2******** *******@TK2MSFT NGP12.phx.gbl.. .
I've not made myself clear.

I can open a new window with javascript no problem. But then I dont want
to pass a url to the window I need to write to it using the Response
stream.

The current system cause an IO nightmare because it writes an HTML page to
disk then opens a window pointing to that page.

I need to get the same effect without writting to disk.

Thanks

Nov 19 '05 #9
Eliyahu, what should the "target" be good for?

Anyway, Josh you can write to the new window with JavaScript on the client.
But this is dangerous if someone have Javascript disabled.
"Eliyahu Goldin" wrote:
Set

<base target="_self">

in the <head> section of the page that you show in the new window.

Eliyahu

"Josh" <s@a.com> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
Hi,

Anyone know how to open a New Browser window and then "response.write " to
the new window. I know how to open a new window, but then targeting
response.write at it is a mystery.

I need to keep the original window open as well as the new one.

Can anyone help?


Nov 19 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
7625
by: monika | last post by:
Hi all... I am able to select a student's story and open it in a word doc. the teacher then corrects the story, highlight in colors the comments, strikethrough. In fact all the privileges I wanted as an editor can be achieved. This word doc gets opened in a new window ... the best part now I have 2 buttons on a page. One which would open a separate window to a word doc and another I want it to open in another asp page. since I have...
3
3134
by: Leonard | last post by:
I have a button on my web app, that opens a help html page. I use this code: HttpContext.Current.Response.Write("<script>") HttpContext.Current.Response.Write("window.open('" & sUrl & "','_new')") HttpContext.Current.Response.Write("</script>") This works ok, the html page opens in a new browser window, but when I close the help, click on a different menu item in my app, and then click the back button, the help window opens up again....
2
2025
by: Mike Lambert | last post by:
I want to be able to open another web page in a new browser window from the one I am currently on? How do I accomplish this? I am currently just using the response.redirect method but can't find a way for it to open the page in a new window. Thanks Mike
3
3567
by: ODB | last post by:
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
3
9756
by: Stephen Witter | last post by:
I am currently using response.redirect in a aspx to go to a web page. What I want is to open the page in a new window. My dotnet code is as follows: Dim sFileName as string = "/TempReports/tempReport.pdf" response.redirect(sFileName) This opens in the same frame and I want to use something like window.open so I can force a new page and control the size of the window, etc.... One thing I thought about is calling a javascript
1
386
by: bucrepus | last post by:
I know response.redirect doesn't open a new page. I have read many posts on how to fix this but I can't get the first one to work. Please help.. I have tried on 2 diff dev machines with no success (VS 2003) ASP.NET Web appl. with Java Script setting in design properties. I created a simple app with one button, under this button I have tried: just to test the command Page.RegisterStartupScript I tried: Page.RegisterStartupScript("TEST",...
11
4927
by: Dave | last post by:
For some reason, the below lines only work on select machines. All machines are running IE6. IE SP's and OS's vary. When it doesn't work, default.aspx (the page that this code is in) opens and closes. That's all you see. TSReminder.aspx doesn't even open. I'm not sure what's going on here. Response.Write("<script...
1
3467
by: dnes | last post by:
Open Multiple New Browser Windows from ASP.NET I'm having trouble figuring out how to open multiple new browser windows (each one displaying something different). As you can see from the code below, I have one ASP.NET page that has a foreach loop, and inside this foreach loop, I was to spawn a new browser window using the second ASP.NET page. This doesn't work. Only the last time through the foreach loop causes a new browser window...
3
6629
by: | last post by:
Hello, I try to open a new Window in code behind with : ClientScript.RegisterClientScriptBlock(this.GetType(), "MyOpenScript", "window.open('toto.doc');", true); My problem is that the new window is created but it disappears immediatly just after creation!! For information, I tried this:
0
8168
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8614
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8330
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8471
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6107
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4167
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2603
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1780
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1474
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.