• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

RH2020 (Update4): Table header

Participant ,
Jun 04, 2021 Jun 04, 2021

Copy link to clipboard

Copied

Hi

I am using RH2020 (update 4) Frameless skin for my project.

I would like to know how can I set the first row of the table as table header. I have created a style for the table but I couldn't find an option to set the first row as the table header. Can this be done in the Table styles or do I need to specify it in the HTML code. 

TOPICS
New UI

Views

237

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Jun 04, 2021 Jun 04, 2021

Copy link to clipboard

Copied

Here's the easiest way I've found to create tables with a header row in RH:

  1. Click the table creation icon on the top toolbar. Choose the number of rows and columns you need.
  2. When the table is created, click on it and then open the Table Properties pane on the right.
  3. Choose the table template that has the orange colored header row (hdrevenrows).
  4. I then altered the class definition for the "hdrevenrows" table in my CSS to use our corporate color palette, etc.

The HTML for the table needs to have a <thead></thead> section where the header row lives.

<table class="hdrevenrows">
    <thead>
      <tr>
        <td>Property</td>
        <td>Values</td>
        <td>Description</td>
      </tr>
    </thead>
    <tbody>
	  <tr>
        <td>Property</td>
        <td>Values</td>
        <td>Description</td>
      </tr>
	</tbody>
</table>

I hope this helps!

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Jun 04, 2021 Jun 04, 2021

Copy link to clipboard

Copied

You might also find this context menu option handy for tables that already exist.

2021-06-04_14-50-02.png

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
Jun 05, 2021 Jun 05, 2021

Copy link to clipboard

Copied

Thank you KarenMinOR

Are you saying that for every table in the project I will need to either add the "th" tag or use the "Convert to Header" option? The project I am handling has got multiple tables. 

 

I was wondering if it is possible to create a Table style wherein I can specify the first row as the Header so that once I apply the style to a table it automatically considers the first row as the Header. 

 

In the style sheet, when we create a new style, it has two tags in it - "th" and "thead". Does this help in creating Tables with Header rows?

 

Table.PNG

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jun 06, 2021 Jun 06, 2021

Copy link to clipboard

Copied

You can format the first row so it's looks like a header row using the style editor. It won't be a th or thead semantically, but you might not care about that.  To format the first row, open your table style in the editor, in the Apply Formatting to field select 'First Row' and define the formatting you want (e.g. shading, bold, etc).

 

Otherwise, yes, you'll need to convert the first row of cells to th for every table. And I couldn't find a way of inserting thead using the menus, so you'd need to go into code view and enter that manually.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jun 06, 2021 Jun 06, 2021

Copy link to clipboard

Copied

I understand that <thead> will be added in an update, also that <th> can be applied to the code but the table code is complex.

________________________________________________________
See www.grainge.org for free Authoring and RoboHelp Information

Help others by clicking Correct Answer if the question is answered. Found the answer elsewhere? Share it here. "Upvote" is for useful posts.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jun 06, 2021 Jun 06, 2021

Copy link to clipboard

Copied

Rereading the information I was given, you should be able to apply <thead> in the code as well.

________________________________________________________
See www.grainge.org for free Authoring and RoboHelp Information

Help others by clicking Correct Answer if the question is answered. Found the answer elsewhere? Share it here. "Upvote" is for useful posts.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
Jun 12, 2021 Jun 12, 2021

Copy link to clipboard

Copied

Hi

What does the "Convert to Header" do? I applied it to the first row of my table and in the PDF output the table header did not repeat.

All I did is inserted a table from the top ribbon and applied the "Convert to Header" option to the first row. Did not apply any customised styles. Added multiple rows and then generated a PDF output. But unfortunately the header did not repeat. 

This is how I applied the style:

  • Inserted a table.
  • Highlighted the first row
  • Right-clicked the first row and then clicked Convert to Header.

Are there any other steps I need to follow while applying the "Convert to Header" style?

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jun 13, 2021 Jun 13, 2021

Copy link to clipboard

Copied

LATEST

Applying TH to the first row simply renders the text to centre aligned bold (the HTML default) unless you have changed the definition in your CSS.

 

In Word you can set the first row of a table to repeat on page split but that is applied in the document. My site has macros that will run through Word documents and allow you to apply that to all tables or selected tables.

 

I think right now all you can do is generate to Word and run one of those macros.

 

I believe Adobe will be looking at THEAD and TH in future updates. I don't know if that will fix the issue in either PDF or Word. Word, for example, is looking for the tables to have the repeat setting applied rather than looking for any HTML tag.

________________________________________________________
See www.grainge.org for free Authoring and RoboHelp Information

 

 

Help others by clicking Correct Answer if the question is answered. Found the answer elsewhere? Share it here. "Upvote" is for useful posts.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
RoboHelp Documentation
Download Adobe RoboHelp