Skip to main content
Inspiring
August 19, 2015
Answered

RH9: How do I get a CSS class or id defined style to get applied to Word or PDF output using <div> tags?

  • August 19, 2015
  • 1 reply
  • 581 views

I have the following written up in RH:

The code behind it is:

The CSS id "DivNote" is defined:

However, when I generate the printed output, I get this:

The style for the Note is gone.

I created a class="Note"... :

...and applied it to the div with similar results but with some of the styling coming through:

The HTML (.chm) output looks fine as does the preview (Ctrl+W) view.

Your help is graciously appreciated.

Steve Roehrig

This topic has been closed for replies.
Correct answer Peter Grainge

In RoboHelp are you mapping to a Word template or just selecting a CSS?

I suspect you are you selecting a CSS and that the solution might be to map to a Word template where you can map the .Note style.

Mapping to Word takes longer to set up the first time but once done you  may find it easier to get the desired results.


See www.grainge.org for RoboHelp and Authoring tips

@petergrainge

1 reply

Peter Grainge
Community Expert
Peter GraingeCommunity ExpertCorrect answer
Community Expert
August 20, 2015

In RoboHelp are you mapping to a Word template or just selecting a CSS?

I suspect you are you selecting a CSS and that the solution might be to map to a Word template where you can map the .Note style.

Mapping to Word takes longer to set up the first time but once done you  may find it easier to get the desired results.


See www.grainge.org for RoboHelp and Authoring tips

@petergrainge

Use the menu (bottom right) to mark the Best Answer or Highlight particularly useful replies. Found the answer elsewhere? Share it here.
SGRoehAuthor
Inspiring
August 28, 2015

Hi Peter,

Again you are right on target. This was a pain to get the mapping between the CSS and Word template to work but after trial and error I indeed got it to work. The main issue was getting the styles I wanted to map even to show up in the final printed output dialog in RoboHelp. Eventually they both "appeared" and I was able to map them for the final output.

Thanks again for your help!