Print Scaling not working in WinForms app

3 posts, 0 answers
  1. B
    B avatar
    5 posts
    Member since:
    Jun 2013

    Posted 03 Jan 2019 Link to this post

    In my Winforms app I have a GridView and the option for users to print the data contained in the GridView.

    The GridView is dynamic in that the number of columns of data varies by user and their department (some users will see 5 columns of data, some will get 10, some will get 13, etc.).

    When printing, due to the unknown number of columns, all the data/columns sometimes will appear efficiently on an 8.5 X 11 sheet of paper in portrait mode and sometimes not.  Sometimes the paper size will have to be changed or the orientation.

    However, if the number of columns is large, even if the orientation is changed to landscape and paper size changed to legal, the data won't display well on the printed report.  It'll either condense/truncate each column to fit on a printed page, or some columns just don't get printed at all (i.e. columns 1 thru 7 will display on the printed page, but columns 8 thru 15 are omitted from the printed results.)

    When printing the GridView's data, 3 options are available in PrintPreview->Print Settings: FitPageWidth, NoFit and NoFitCentered.  Neither of these options produce a report in which all the data/columns are readable. 

    Is there a way to have all columns printed at their actual size, in that if the number of columns is too many to fit on a single sheet of paper, the first "batch" of columns will print on "page 1" and the second batch on page 2?  (Similar to the "No Scaling" print option in Excel.) 

    Internally, when printing the GridView's data, the GridView's data is passed to the Associated Object of a RadPrintDocument.  That RadPrintDocument is then passed to the Document property of a RadPrintPreviewDialog.

    Thanks much for all advice with this matter.

  2. B
    B avatar
    5 posts
    Member since:
    Jun 2013

    Posted 07 Jan 2019 in reply to B Link to this post

    Telerik, it's been 4 days since this was submitted.  Please reply.
  3. Dess | Tech Support Engineer, Sr.
    Admin
    Dess | Tech Support Engineer, Sr.  avatar
    3907 posts

    Posted 08 Jan 2019 Link to this post

    Hello, Bret,  
     
    I would like to note that initially this thread was posted in the Telerik Reporting forum. However, your question seems to be related to the Telerik UI for WinForms suite. I have changed the product of this thread.  RadGridView offers Multi-page printing in order to print wider columns. It is supported for grids with ViewDefinition set to TableViewDefinition. To enable the functionality you should define the collection of columns each page will contain. For this purpose you can use the PrintPages collection of the TableViewDefinitionPrintRenderer. The PrintPages collection contains collections of columns, each representing a separate page. Please refer to the following help article: https://docs.telerik.com/devtools/winforms/controls/gridview/printing-support/gridprintstyle
     
    Off topic, note that most of the forum threads are reviewed by Telerik representatives and sometimes we address the questions asked by our customers in the forums as well. However, a post in the forum doesn't guarantee you a response from the Telerik support team. Moreover, threads are handled according to license and time of posting, so if it is an urgent problem, we suggest you use a support ticket, which would be handled before a forum thread.

    I hope this information helps. If you need any further assistance please don't hesitate to contact me. 

    Regards,
    Dess | Tech Support Engineer, Sr.
    Progress Telerik
    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Back to Top