|
Rank: Member Groups: Member
Joined: 2/21/2012 Posts: 12
|
Is there a way to disable the Repeating Table Header and Footer? This feature is described here: http://www.essentialobjects.com/doc/4/htmltopdf/table_header.aspxOur client does not want this feature.
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi,
You will have to replace thead and tfoot with tr. As soon as you use thead and tfoot, the converter will repeat them.
Thanks!
|
|
Rank: Member Groups: Member
Joined: 2/21/2012 Posts: 12
|
We can't just change the thead and tfoot with tr because all of our CSS is dependent on these tags. Can you please flag for a future feature?
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi, We will think about that but there is no guarantee at this moment yet. In the mean time if possible, try to add the following attribute to your CSS:
Code: CSS
thead
{
display: table-row;
}
That should take care of it. Thanks!
|
|
Rank: Member Groups: Member
Joined: 2/21/2012 Posts: 12
|
I tried your trick for both thead and tfoot but it just moved the header and footer to the top of the grid and removed all formatting.
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi,
You will need to physically move your tfoot to the end of the table. Our rendering engine recognizes whether a row is a thead or a tfoot by checking its "display" property. By default the display value is "table-header-group" for thead and "table-footer-group" for tfoot. Those two values are what give the header and footer special treatment: putting header at top, footer at the bottom and automatically repeat them on every page. Overriding the display value would turn off all these special treatment. So it no longer automatically put your tfoot row at the end. So you will have to do that explicitly in your HTML.
I do not know why it would remove your formatting. You are supposes to add that the display attribute to your existing rules instead of replacing them. If you just replace your existing rules, then obviously you will lose your formatting.
Hope this helps.
Thanks
|
|
Rank: Member Groups: Member
Joined: 2/21/2012 Posts: 12
|
We are using a third party control for grid generation and have no control how they construct the HTML. Apparently they put the tfoot at the beginning of the table.
As stated, the best solution for us would be to disable the repeating header/footer via a property in HtmlToPdf.Options. To be explicit, I want the PDF to exactly match what is seen on the screen without adding anything even if you think it might help the user.
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Yes. We understand that part. We were just trying to provide you a workaround before that is implemented. If that does not work for you, then you will have to wait for the new option to be added.
Thanks!
|
|
Rank: Member Groups: Member
Joined: 2/21/2012 Posts: 12
|
I now have another reason I want to disable this. If I have a grid that extends past the page, anything that is the same level as the grid header is being repeated on every page. Example: Grid 1 & Image 1 are side by side. Grid 1 extends to 2 pages. Image 1 easily fits on the first page. However, when the PDF is rendered, the header for Grid 1 and the top of Image 1 appear at the top of page 2. I can send you a PDF with this in it if you would like.
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi,
This is a different issue. I believe it's a bug that has already been fixed. We will PM you with a new build that supposes to fix this problem.
Thanks!
|
|