Skip to main content
Known Participant
December 22, 2015
Question

whtopic.js error

  • December 22, 2015
  • 1 reply
  • 2312 views

I inherited a RoboHelp project and realized instead of publishing the compiled project, they were simply copying any changed files to the server.  I began publishing the project and our software program began throwing an error related to the whtopic.js file.

Error: The value of the property 'onSetStartPage' is null or undefined, not a function object

URL points to the whtopic.js file contained in Web Help

The coder added the bold line to the code, which seemed to solve the problem.

  gsPPath=_getFullPath(_getPath(document.location.href),
_getPath(sPath));

if (typeof (onSetStartPage) != "undefined")

            onSetStartPage();

My first question, of course, would be, what causes the error and how did the code update fix it.  I also wanted to mention after reviewing WebHelp on the server, I noticed there are multiple instances of the whtopic.js file, as well as another instance of the WebHelp project nested in the original.  Would these be causing conflict?  I'm wondering if it would be safe to delete the entire Web Help project from the server and re-publish everything fresh to see if it corrects the issue.  If not, any suggestions?

This topic has been closed for replies.

1 reply

Jeff_Coatsworth
Community Expert
Community Expert
December 22, 2015

I’m presuming that your application is the one calling the help? What happens if you just browse to the location & open up the index page of the webhelp? Do you get any errors thrown then?

CAMS-HelpAuthor
Known Participant
December 22, 2015

You are correct, the application is calling the Help file. When I browse to the server location and open the index page, there are no errors.

Jeff_Coatsworth
Community Expert
Community Expert
December 22, 2015

So you could conclude that the multiple copies you find are messing up which one the app opens & test by backing it all up & reimporting the complete \!SSL!\WebHelp\ contents again.