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

How do I get the Print button to print just the Topic Content?

New Here ,
Sep 04, 2013 Sep 04, 2013

I have inserted a Print button into the Topic layout of my project.

However when you use it (in the generated project) it is also printing the Search field, Home, Index buttons etc.

Honestly, in the Android HTML5 layout this looks terrible .... is there any way to fix this so it prints JUST the content and not the other stuff?

OnlineHelp.PNG

608
Translate
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
LEGEND ,
Sep 05, 2013 Sep 05, 2013

The android layout is not designed to be printed. But you can do this easily by adding an @print media query

In the layout css, add the media query:

@media print {

}

Just add all elements you want to hide in the media query and give them the styling 'display: none;'

All the desktop layouts have the print styles included.

Greet,

Willam

Translate
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
New Here ,
Nov 03, 2013 Nov 03, 2013

Hi William

Bit of a delay, but this has popped up again.

Can you give me an example of how the 'elements' would appear in the media query?

Is it possible to add the print styles from the desktop layout to the android layout somehow??

Translate
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
New Here ,
Nov 05, 2013 Nov 05, 2013
LATEST

Hi Willam

I have figured it out, thanks for the lead ...

For those who read this and are trying to do the same.

I added this to the mobile.css file:

@media print {

   a.wPrintButton {

display:none;}

div.searchholder{

display:none;}

div.header {

display:none;}

div.wTopic {

border: 0px solid #000;}

table.searchholdertable{

display:none;}

div.options{

display:none;}

div.contentholder {

border: 0px solid #000;}

}

Translate
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