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.
Unfortunately, activation email could not send to your email. Please try again.

format table cells

Thread ID:

Created:

Updated:

Platform:

Replies:

42120 Mar 20,2006 01:45 PM Mar 22,2006 06:14 AM Windows Forms 3
loading
Tags: PDF
Administrator [Syncfusion]
Asked On March 20, 2006 01:45 PM

I have created a table to be published from a dataset. Is there any way to go through the cells of the pdf table and change the width/height based on the the data that is in that cell?

Ajish [Syncfusion]
Replied On March 21, 2006 04:02 AM

Hi Matt, We can change the width/height of rows and columns based on the data that in that cell. 1) To change the column width use table.Columns[ index ].Width 2) To change the row height use table.Rows[index].Height 3) To get the Column name of the data source use table.Columns[ index ].DataColumnName 4) To measure the size of the string use MeasureString() Method of IPDFGraphics. Please let me know if you have any other questions. Regards, Ajish. Here is a sample for you to refer >I have created a table to be published from a dataset. Is there any way to go through the cells of the pdf table and change the width/height based on the the data that is in that cell?

Administrator [Syncfusion]
Replied On March 21, 2006 12:46 PM

I see in that example, measureString is used on the dataColumnName, but I want to measure the string that is in the cell. I have tried using Table.rows(i).cells(j).Value to get the contents of the cell, but that always returns a null value. Is there a way to get the contents of the table cell? >Hi Matt, > >We can change the width/height of rows and columns based on the data that in that cell. > >1) To change the column width use > >table.Columns[ index ].Width > > >2) To change the row height use > > >table.Rows[index].Height > > >3) To get the Column name of the data source use > > >table.Columns[ index ].DataColumnName > > >4) To measure the size of the string use MeasureString() Method of IPDFGraphics. > >Please let me know if you have any other questions. > >Regards, >Ajish. > > >Here is a sample for you to refer > > > >>I have created a table to be published from a dataset. Is there any way to go through the cells of the pdf table and change the width/height based on the the data that is in that cell?

Ajish [Syncfusion]
Replied On March 22, 2006 06:14 AM

Hi Matt, Currently in Essential PDF, it is only possible to set the height of the entire row or width of the entire column as whole it is not possible to have separate width/height dimension for a single cell. Regarding cell value issue table.Row[ index].cell[index]. Value is used to set value to a particular cell and it cannot be used to get value of the cell. However I will consult with development team and will update you when I hear back. Thanks, Ajish.

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.

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.

;