Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
550
BUG? UltraGridPrintDocument does not print WYSIWYG
posted

Hello, 

the UltraGridPrintDocument should print WYSIWYG by default, that's what I thought. But printing a Grid, where all the columns are displayed correctly on screen, takes away 1 character from the values in almost every column when printed (or in the PrintPreview). Now, the values are shortened and an ellipsis is shown.

That's all I coded:
ultraGridPrintDocument.Grid = this.gridReport;
ultraGridPrintDocument .Print();

Is there an easy way to get WYSIWYG, instead of working around in InitializePrint or InitializePrintPreview with column.PerformAutoResize?

Thanks for your help!

Parents
No Data
Reply
  • 469350
    Verified Answer
    Offline posted

    The grid DOES print WYSIWYG. The problem is that the screen uses different drawing units than the printer. So the width of the column on-screen may fit the text perfectly, but when the same width is used on a printer, the text may not fit the same. 

    Calling PerformAutoResize on each column on the print layout accounts for this, since the print layout knows to use printer metrics and not screen metrics. 

Children