We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

XlsIO excel document silent print (as Image) and fit columns

Thread ID:

Created:

Updated:

Platform:

Replies:

121508 Dec 20,2015 06:04 PM UTC Dec 22,2015 11:44 AM UTC WinForms 1
loading
Tags: XlsIO
Sychev Stepan
Asked On December 20, 2015 06:04 PM UTC

Good day!
I need the silent print the excel document. I have used sheet.ConvertToImage() method.
But.. I need to fit all columns to the one screen (var lastColumn = sheet.UsedRange.LastColumn + 1). So I need to know the row count on each print page (Image). E.g. 10 rows on first page sheet.ConvertToImage(1,1,10,lastColumn), 12 rows on second page sheet.ConvertToImage(11,1,22,lastColumn).. etc.
How can I calculate this row count per each print page?

Dilli Babu Nandha Gopal [Syncfusion]
Replied On December 22, 2015 11:44 AM UTC

Hi Sychev,

In XlsIO, you can explicitly convert the range of the worksheet using ConvertToImage( int firstRow, int firstColumn, int lastRow, int lastColumn ) method. This method will return a single image for the entire specified range. To convert an image page-wise, you must create a custom method which calculates number of rows to be converted based on row height so that array of images will be converted for entire range.
 
Please refer our UG Documentation for Worksheet to Image conversion from the below link.

Documentation link: http://help.syncfusion.com/file-formats/xlsio/conversions#convert-worksheet-to-image

Please let us know if you have any concerns.

Regards,
Dilli babu.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;