Skip to main content
NocturneGames
Participating Frequently
June 23, 2020
Answered

How To Write A Simple Script (RoboHelp 2019)

  • June 23, 2020
  • 2 replies
  • 573 views

Hello! I would like to use the RoboHelp 2019 scripting functionality to perform what seems like (to me) a simple task, but I have zero experience using scripting and the Official documentation doesn't seem to cover it at all.

 

Basically I'd like a script that goes through a specific folder that I point to, and then takes the title from the metadata htm title and adds it to the index metadata of each document in the folder.

 

Any help writing this, or pointers to simple resources that I can learn from, would be very much appreciated.

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

The task might be simple but scripting isn't. It's mostly a task for developers. In 2019 the scripting is javascript so maybe you have a friendly developer or one who can be corrupted with doughnuts?

 

2 replies

Community Expert
June 24, 2020

Just some random info for people following along who might want to dabble (that's what I'm currently doing). It's brief, but hopefully will get those with enough knowledge to be dangerous started. 🙂

 

There are a bunch of scripting libraries built in to RH; electron.js and node.js being key ones. Also jquery. So start here for researching js scripting.

 

To get in to debug in RH, press Ctrl+Alt+D.

 

Then, so you don't have to debug all of Adobe's scripts, open scripting.js and click the pretty print icon in the bottom left of the code window. (I really wish this was an automatic thing as you have to do this each time. 😞   )

 

Search for the function 'static execute(e)'

 

Set a breakpoint on a = new Function(n.code)

 

Then when you run your script, the code will break, click Step Into and you'll be able to debug your script.

Peter Grainge
Community Expert
Peter GraingeCommunity ExpertCorrect answer
Community Expert
June 23, 2020

The task might be simple but scripting isn't. It's mostly a task for developers. In 2019 the scripting is javascript so maybe you have a friendly developer or one who can be corrupted with doughnuts?

 

Use the menu (bottom right) to mark the Best Answer or Highlight particularly useful replies. Found the answer elsewhere? Share it here.
NocturneGames
Participating Frequently
June 23, 2020

Thank you for the reply Peter. As It happens I do have support from the dev team, so I'm sure I can get them to look at this for me (the person I'm thinking of I can bribe with Pringles rather than donuts!).