Forum Moderators: open

Message Too Old, No Replies

Print Button Alert

Trying to put an intermediate altert between the good old Print button

         

markd

9:32 pm on Jul 11, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hello all

I am using a Javascript 'print' button and hyperlink which allows the user to automatically open the print dialogue box in IE in the usual way.

I'm using:

window.print()

Is there any way I can put an alert which will appear after the user has pressed the print function, to say..

'please adjust your print settings to landscape A4 before printing this page'.

The user would then 'OK' the alert and the print dialogue box would appear as usual.

Any help much appreciated.

Thanks

Rambo Tribble

9:43 pm on Jul 11, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Just call the alert() method before you invoke the window.print() method. For instance, if you are using a button with the onclick calling the methods:
onclick="alert('Adjust your etc.~');window.print();"