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

Variables in RoboHelp 7

Explorer ,
Nov 12, 2009 Nov 12, 2009

Copy link to clipboard

Copied

Hi,

I have a little Javascript script in each of my topics that launches a link in a window.  It's in Javascript because I need to set the window size.

It includes two Javascript variables - one for the server location of the file being launched, and one for the specific directory and file info.  It' works beautifully.

I would like to use the RoboHelp variables to set a global variable for the server location so when we move the files or set them up on a client's server, I can make one change.  I searched here and found FAR, which I can use as a last resort.

But is there a way to make Javascript recognize a RoboHelp variable?  I get no reaction if I insert it directly into the script.

Thanks, as always, for any help.

Views

447

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 ,
Nov 12, 2009 Nov 12, 2009

Copy link to clipboard

Copied

Hi there

Likely that will be a futile process. I say that because when you create and use a JavaScript variable, you are creating something intended to survive the Compile or Generation process. Think of it as mixing a bowl of batter and adding chocolate chips. In this case, the chocolate chips are the JavaScript variables. They end up in the baked product.

RoboHelp variables are similar to Hershey's kisses. They look like chocolate chips, but before you bake them, the wrappers must be removed.Or possibly muffin tins. You are reserving a spot for something to end up in. What goes in there actually changes before the baking occurs.

Basically, the RoboHelp variables are intended to serve as placeholders. When you generate or compile, the placeholders are replaced by the actual content. So even though it was a variable, it was only a variable until you compiled or generated. Then it became content.

Hopefully that wasn't very confusing.

Cheers... Rick

Helpful and Handy Links

RoboHelp Wish Form/Bug Reporting Form

Begin learning RoboHelp HTML 7 or 8 within the day - $24.95!

Adobe Certified RoboHelp HTML Training

SorcerStone Blog

RoboHelp eBooks

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, 2009 Nov 12, 2009

Copy link to clipboard

Copied

Hmmm.

What if I had the RoboHelp variable equal something like "Var SiteName=www.adobe.com"? Would that insert the line of code into the Javascript code?

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 ,
Nov 12, 2009 Nov 12, 2009

Copy link to clipboard

Copied

Hi again

If it were RoboHelp 8, you could format the variable and have it become an actual hyperlink. But as you have stated you are using 7, I would expect it to result in static text that would be totally visible to the end user, as if you just typed it on the page.

I'm guessing you should consider submitting a Wish Form to ask the development team to consider a means whereby a RoboHelp variable could be used in conjunction with a JavaScript variable.

Cheers... Rick

Helpful and Handy Links

RoboHelp Wish Form/Bug Reporting Form

Begin learning RoboHelp HTML 7 or 8 within the day - $24.95!

Adobe Certified RoboHelp HTML Training

SorcerStone Blog

RoboHelp eBooks

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, 2009 Nov 12, 2009

Copy link to clipboard

Copied

LATEST

Yes, that's what happened before when I tried to find a way to use it.

Thanks anyway, Rick!

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