473,800 Members | 2,413 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

WebBrowser.Prin t

Using C# 3.5 ...

How can I set the default page orientation to Landscape when using
WebBrowser.Prin t( )?

.... Thom
_______________ _______________ _______________ ______
Thom Little - www.tlanet.net - Thom Little Associates, Ltd.
Jun 27 '08 #1
2 3274
Page.DefaultPag eSettings.Lands cape = true;

Hope this helps.

"Thom Little" <th**@tlanet.ne twrote in message
news:%2******** ********@TK2MSF TNGP03.phx.gbl. ..
Using C# 3.5 ...

How can I set the default page orientation to Landscape when using
WebBrowser.Prin t( )?

... Thom
_______________ _______________ _______________ ______
Thom Little - www.tlanet.net - Thom Little Associates, Ltd.
Jun 27 '08 #2
I am too ignorant to see how it helps.

All it takes to print the current area displayed in a WebBrowser control
called wbMain is ...

private void printToolStripM enuItem_Click(o bject sender, EventArgs e)
{
this.wbMain.Pri nt();
}

How do I expose the "Page" to which you refer?

.... Thom
_______________ _______________ _______________ ______
Thom Little - www.tlanet.net - Thom Little Associates, Ltd.
Jun 27 '08 #3

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

Similar topics

5
7327
by: John Bowman | last post by:
Hi, I've been reading through the threads on using the WebBrowser control in C# app's and how to print it's contents. I've got that much working. However, the big problem is I can't figure out how to detect when the printing is finished. I've read the article "Printing with the Internet Explorer WebBrowser Control" and it mentions some sample code in pwaitvb. This example pretty much useless to me because VB hides the how to do it. I...
1
2244
by: JerryShea | last post by:
Hi, I am opening a word document (RTF) in a webbrowser control and automating it. Most automation features seem to work but when I execute: wordApp.ActiveDocument.PrintPreview() I get an exception thrown: "Requested view is not available." Can anyone help me to get this document to preview?
1
2078
by: eskildb | last post by:
First, please be gently. I am fairly new to the programming world (1.5 years with some expermentation prior to). I have been working on a project that has to print HTML pages with graphics in a unattended automated fashion. I have a webbrowser that is created with code but not seen. I found the below code on the internet. It creates a webbrowser, and specifies the URL, which navigates the webbrowser to the page. When the document is...
1
2940
by: eskildb | last post by:
First, please be gently. I am fairly new to the programming world (1.5 years with some expermentation prior to). I have been working on a project that has to print HTML pages with graphics in a unattended automated fashion. I have a webbrowser that is created with code but not seen. I found the below code on the internet. It creates a webbrowser, and specifies the URL, which navigates the webbrowser to the page. When the document is...
12
6381
by: Alex Clark | last post by:
Greetings, (.NET 2.0, WinXP Pro/Server 2003, IE6 with latest service packs). I've decided to take advantage of the layout characteristics of HTML documents to simplify my printing tasks, but of course it's thrown up a whole host of new issues... I'm generating a multi page printable document in HTML from my app, and displaying it in a WebBrowser control. I've looked into using some CSS
2
2643
by: johnb41 | last post by:
I'm using .NET 2.0. My form is displaying the webbrowser control, which is displaying some HTML text. When printing with webbrowser.print(), my printout includes the header and footer. How can I remove the header and footer from the print out? Can this be done? If i can suppress the header and footer, i think this might be a really
8
4636
by: Dustan | last post by:
At http://docs.python.org/whatsnew/modules.html on the webbrowser module, it says "A number of additional browsers were added to the supported list such as Firefox, Opera, Konqueror, and elinks." I just installed python 2.5, looking forward to being able to control firefox without having to make it my default browser, but... I don't seem to have that functionality. In IDLE: {'windows-default': }
4
12501
by: jwgoerlich | last post by:
Hello group, I have a project with several WebBrowser objects on separate tabs. I want to take screenshots of these. I am currently using the PrintWindow function. (Code below.) This works if the tab is open and the WebBrowser is displayed. For browsers on other tabs, however, the resulting bitmap is black. Any ideas on how to tweak this code so that it snapshots WebBrowsers on tabs that are not selected? Or should I be using a...
1
1770
by: Meels Lilbok | last post by:
Hi Im usin a WebBrowser control on my C#/WinForm application. There are 2 options for user, 1) Print output to PDFPrinter or 2) Print output to default system printer. In code i change default printer and then call theWebBrowser.Print() method. All works fine but... browsercontrol "remebers" only first printer change.
1
12620
by: Tim Sprout | last post by:
I want to call Page Setup to set default printer and page size and orientation before batch printing pdf's silently from WebBrowser controls. I can print silently using DDE (the NDde library) or Adobe Interapplication Communication (IAC) DotNet API. There is no Adobe DDE command or IAC API for Page Setup. I don't see a print silent method for the WebBrowser control. I can get a Page Setup dialog to appear by using the code below, but the...
0
9691
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10505
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10035
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
7580
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
6813
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5471
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5606
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4149
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
3
2945
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.