I am having a problem with window.print in a popup window.
I am creating 2 popup windows both with a print button in them, 1
works the other doesn't. Code runs in a javascript function on a
webpage. Here is the difference :
First example (works) -
mywinman=window.open('t&cs.htm','win2','toolbar=no ,location=no,directories=no,status=no,menubar=no,s crollbars=yes,resizable=no,width=600,height=500,le ft=100,top=100');
htm file contains this button -
<INPUT type='button' value='Print' OnClick='window.print()'>
Second example (no errors but nothing happens) -
mywin=window.open('','win1','toolbar=no,location=n o,directories=no,status=no,menubar=no,scrollbars=y es,resizable=no,width=550,height=600,left=50,top=5 0');
content created using document write in a loop as follows :
mywin.document.write(html_line [i]);
code is in the line eg.
html_line [idx] = "<INPUT type='button' value='Print'
OnClick='window.print()'>";
It seems that somehow I am not specifying the window correctly
although I have tried various combinations.
I am sure it is something stupid as usual. Thanks in advance.
John 1 7821
On Thu, 14 Aug 2003 21:41:26 +0000 (UTC), John <j@laycus.con> wrote: I am having a problem with window.print in a popup window.
I am creating 2 popup windows both with a print button in them, 1 works the other doesn't. Code runs in a javascript function on a webpage. Here is the difference :
First example (works) -
mywinman=window.open('t&cs.htm','win2','toolbar=n o,location=no,directories=no,status=no,menubar=no, scrollbars=yes,resizable=no,width=600,height=500,l eft=100,top=100');
htm file contains this button - <INPUT type='button' value='Print' OnClick='window.print()'>
Second example (no errors but nothing happens) -
mywin=window.open('','win1','toolbar=no,location= no,directories=no,status=no,menubar=no,scrollbars= yes,resizable=no,width=550,height=600,left=50,top= 50');
content created using document write in a loop as follows :
mywin.document.write(html_line [i]);
code is in the line eg. html_line [idx] = "<INPUT type='button' value='Print' OnClick='window.print()'>"; It seems that somehow I am not specifying the window correctly although I have tried various combinations.
I am sure it is something stupid as usual. Thanks in advance.
John
BTW Just noticed it works fine with Netscape 7 but not IE6 This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Bruce Davis |
last post by:
I'm having a problem on windows (both 2000 and XP) with a multi-threaded
tkinter gui application. The problem appears to be a deadlock condition
when a child thread pops up a
Pmw dialog window in...
|
by: Marcus Bjorke |
last post by:
I use a print link that causes a problem with Opera 7. The link looks
like this <a href="javascript:parent.frames.mainFrame.print()">Print
this page</a>
I also used
<a...
|
by: syed_saqib_ali |
last post by:
Below is a simple code snippet showing a Tkinter Window bearing a
canvas and 2 connected scrollbars (Vertical & Horizontal). Works fine.
When you shrink/resize the window the scrollbars adjust...
|
by: dibyendu_k |
last post by:
Hi,
There is a problem i cant solve regarding Internet Explorer 5.5. It is regarding the Print Dialog Box.
From a webpage if I open a popup window (window.open()) containing buttons Print and...
|
by: Stewart Midwinter |
last post by:
I have a Tkinter app running on cygwin. It includes a Test menu item
that does nothing more than fetch a directory listing and display it
in a Toplevel window (I'd use a tkMessageBox showinfo...
|
by: makunag |
last post by:
Didn't get answer with google and in my regular forum. Came across this site and posting here. Your help will be highly appreciated !
Our application have frames - MainNav, TaskNave and Content....
|
by: =?Utf-8?B?aGVsZmk=?= |
last post by:
Hi all,
I have replied with my own questions to an older post entry
but after a while I thought it's better to start a new thread based on
the previous one. Perhaps with the new thread I will...
|
by: neovantage |
last post by:
Hey all,
I am using a PHP script which creates headings at run time in a sense at page execution. I am stuck a with a very little problem which i am sure i will have the solution from experts.
...
|
by: DolphinDB |
last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation.
Take...
|
by: DolphinDB |
last post by:
Tired of spending countless mintues downsampling your data? Look no further!
In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
|
by: ryjfgjl |
last post by:
ExcelToDatabase: batch import excel into database automatically...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM).
In this month's session, we are pleased to welcome back...
|
by: Vimpel783 |
last post by:
Hello!
Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
|
by: ArrayDB |
last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
|
by: PapaRatzi |
last post by:
Hello,
I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
|
by: Defcon1945 |
last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
|
by: af34tf |
last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
| |