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: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to calculate PdfGrid Table Height

 How to calculate PdfGrid table height


Currently Essential Pdf doesn’t provide a property to get the height of a PdfGrid. The code snippets snippets given below explains


//Calculate the PdfGrid Table Height


 PdfLayoutResult result = pdfGrid.Draw(page, new PointF(0, 0));


 float gridHeight = result.Bounds.Height;


 MessageBox.Show(“Table Height ”+ gridHeight);


 To set Page Break in PdfGrid

Essential PDF supports the PdfGrid pagination through the PdfGridLayoutFormat class. We can enable the pagination by using the Pagination property available in the PdfLayoutType enumeration. Please refer the following code snippet:

//Create the PdfGird

PdfGrid pdfGrid = new PdfGrid();

PdfGridLayoutFormat format = new PdfGridLayoutFormat(); format.Layout = PdfLayoutType.Paginate; format.Break = PdfLayoutBreakType.FitElement;

//Draws the grid in to the page of the PDF document using that layoutformat pdfGrid.Draw(pdfPage, new PointF(10, 10),format);


Sample Link to get PdfGrid Table Height:


Sample Link for Page break:




Article ID: Published Date: Last Revised Date: Platform: Control:
2690 11/18/2014 11/18/2014 WinForms PDF
Did you find this information helpful?
Add Comment
You must log in to leave a comment

Please sign in to access our KB

or the page will be automatically redirected to sign-in page in 10 seconds.

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