Hi,
I'm trying to print a UltraGrid by using UltraPrintPreviewDialog and UltraGridPrintDocument, but I can't seem to find how to control the print out page's margin. Currently in the print preview dialog, there are a big blank space reserved on the page above the actual content; is there anyway to adjust that? Also, is there anyway to add header and footer on the final print out? Thanks!
P.S. - I've tried setting doc->Header->Height = 0 and doc->Page->Margins->Top = 0, but it still has a big margin on top of the grid.
The PrintDocument class has a DefaultPageSettings which has a Margins property which determines the print margins for the page. The UltraGridPrintDocument is just a derived PrintDocument so it has this same property.
I'm not sure what you mean about adding header/footer on the "final print out". Are you saying that you want the print preview and print to look different? There is only 1 print document used for both so the settings will affect both.
Hi Andrew,
I am facing same thing. I am using ultraprintpreview control to show print preview of the grid. I want to get rid of blank space at the top and at the left. So I want contenats of document to occupy whole ultraprintpreviewcontrol area. Any ideas, how this can be achieved?