print in landscape mode

N

nuhura01

I want a printing properties to be set to landscape mode, so that when
the user click a print button, it will print in landscape mode
automatically.

I use this code in the code-behind of the web form to print the page:
HttpContext.Current.Response.Write("<script>window.print();</script>")

How could I set it to print in landscape mode? Any solution for
this?

Thanks...
 
E

Eliyahu Goldin

No, you don't have any control other than window.print over the client-side
printers. You can achieve it with an ActiveX or WSH (Windows Scripting Host)
calls but it will require users to set special security for your site.

--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
http://msmvps.com/blogs/egoldin
http://usableasp.net
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,012
Latest member
RoxanneDzm

Latest Threads

Top