Logo
My Account |  Site Map | Contact Us  
Welcome Guest Search | Active Topics | Sign In | Register

Changing the page margins when printing from a WebControl Options
KimKamp
Posted: Tuesday, April 18, 2017 12:53:11 PM
Rank: Newbie
Groups: Member

Joined: 3/13/2017
Posts: 8
I'd like to change the Page Margins for a page that I want to print.

I have created a new EO.WinForm.WebControl. When I load the html for this WebControl, there is a 'Print' button visible. When I click on the Print button, I can select the Printer, but not change the page margins, or the orientation.


I'd like to change the paper margins and orientation when I print the page. How do I change the margins and page orientation for this page when I am printing it?

Thanks!


Kim
eo_support
Posted: Tuesday, April 18, 2017 5:24:04 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 19,152
Hi,

You would either use standard printing dialog or your own custom printing dialog. With the standard printing dialog, you would change the margin/page orientation by clicking the "Preferences" button. With your own custom printing dialog, you would need to display the dialog in the WebView's BeforePrint event and pass the value through e.Continue. See here for more details:

https://www.essentialobjects.com/doc/webbrowser/advanced/printing.aspx

I do not believe you can change orientation with custom printing dialog though, margin should work.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.