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

Back and Print button not working

New Here ,
Sep 19, 2008 Sep 19, 2008

Copy link to clipboard

Copied

Our tech author just managed to get the print and back buttons to display on our webhelppro project, but nothing happens when they are clicked!

Any ideas what might be wrong? I thought once they display, they should work lol

Views

2.9K

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
New Here ,
Sep 22, 2008 Sep 22, 2008

Copy link to clipboard

Copied

OK, i just realised you need to add javascript to print and back buttons to get them to work lol.....ooops.

I go the back button working just fine.

However, i can not get the print to work. This is because i do not know the name of the <iframe> that the main content is displayed in.

I have toolbar up top, toc down left and main content window to right.

Can anyone tell me the name of the content frame?

Im assuming frames are used of course.

Thanks

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
Guest
Oct 06, 2010 Oct 06, 2010

Copy link to clipboard

Copied

What is the javascript for the back button?

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
LEGEND ,
Oct 08, 2010 Oct 08, 2010

Copy link to clipboard

Copied

Hi,

history.go(-1)

Greet,

Willam

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
Guest
Oct 08, 2010 Oct 08, 2010

Copy link to clipboard

Copied

Thanks, but that does not work...

I put a back button in the main toolbar and set that as the ON-click script. No luck.

In order to get the print buttton to work I used...

var printAction=function()

{

var topicPane=top.frame[1}.frames[1];

topicPane.focus();

topicPane.print();

}

I want the back button to return the main frame to the previous content.

Any ideas?

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
LEGEND ,
Oct 08, 2010 Oct 08, 2010

Copy link to clipboard

Copied

Hi,

In your button, go to the Action tab. In the field OnClick, enter top.frames[1].frames[1].history.go(-1);. This will set the topic to the previous topic.

Greet,

Willam

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
Guest
Oct 08, 2010 Oct 08, 2010

Copy link to clipboard

Copied

LATEST

That works.

Thank you.

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 ,
Sep 22, 2008 Sep 22, 2008

Copy link to clipboard

Copied

See Snippet 24 on my site.

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
New Here ,
Sep 22, 2008 Sep 22, 2008

Copy link to clipboard

Copied

quote:

Originally posted by: Peter Grainge
See Snippet 24 on my site.



Thank you Peter, that did the trick :)

I havent done javascript for years and couldnt remember to use top. etc..

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
Explorer ,
Nov 12, 2008 Nov 12, 2008

Copy link to clipboard

Copied

This isn't working for me in RH 7.0.2 (WebHelp, not WebHelp Pro). The new button appears, has hover text and an image, however on click doesn't trigger a print dialogue.

FF 3, IE 8 (yes.. beta)
No pop-up blockers, etc.

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
Explorer ,
Nov 12, 2008 Nov 12, 2008

Copy link to clipboard

Copied

Resolution found 🙂 A posting by "Authorgraphic" on another site (I can only assume this is the same "Authorgraphic" on this forum) posted the following:

"window.parent.frames[1].frames[1].focus();window.parent.frames[1].frames[1].print();

I have tested this in Internet Explorer 7, Mozilla Firefox 3, and it works OK.
It also works in Apple Safari 3.1.2, although the printout it scaled down to
about 80% of correct size (text and screenshots). "

This goes into WebHelp Skin Editor > Toolbar tab > Print Topic > Edit icon. Custom Toolbar Item > Action tab > Javascript OnClick

Entries are not required in the inline javascript section.

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
New Here ,
Nov 14, 2008 Nov 14, 2008

Copy link to clipboard

Copied

I tried your solution and while it worked on my machine when I compiled the help system (clicking the Print button did, in fact, bring up the Print dialog), my client informed me that when she loaded the HTML help system onto the Web site server, it refused to function. She said she received an "Error on Page" message. She also mentioned that when she hovers the cursor over the Print button, the tooltip reads Javascript null. Any thoughts? I am a technical writer working on a help system and my client is beside herself. She really wants this to work although I did tell her that the print functionality in RoboHELP HTML is nonexistent because the help topic opens in a browser window and users will use the print functionality of the browser to print help topics. I confirmed this with Adobe Technical Support; the Print function is only avaliable when building help files in RoboHELP for Word (for stand-alone software program help files), but not in RoboHELP HTML.

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
New Here ,
Jan 25, 2010 Jan 25, 2010

Copy link to clipboard

Copied

I just wanted to let people know that I tried this and it works for both Mozilla Firefox 3.5.7 and Internet Explorer 7.0.

I had gotten a solution (below) in a similar vein about 6-7 years ago from the forums when I first started working with WebHelp. This worked beautifully in Internet Explorer and still does a version or two later. However, the software development company I work for recently starting developing with Firefox. I discovered that if I bring the help up in Firefox using the code below for the "Print Topic" button's onClick command that the browser prints the toolbar frame rather than the current topic frame.

javascript:parent.frames[1].bsscright.focus();window.print();

Whereas window.parent.frames[1].frames[1].focus();window.parent.frames[1].frames[1].print(); works great for WebHelp in either IE or Firefox.

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 ,
Nov 14, 2008 Nov 14, 2008

Copy link to clipboard

Copied

See Snippett 24 on my site.

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