Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

CalendarGen function failing when reloading document in QMC

Hi,

I have created a new calendar document using the CalendarGen function included in the framework, which works perfectly when reloading from the document itself. However I have placed the document into the reload schedule in our management console and it always fails when it gets to the point where it calls the function.

The log doesn't really give any information to why it has failed, and just says:

CALL CalendarGen('date', 'Calendar, '4', '01/09/2006', '31/08/2012')

Error: Script line error:

General Script Error

Does any one have an idea why this would be happening, or how to get any more details about the error?

Thanks

2 Replies
Magnus_Berg
Employee
Employee

Hi James, my guess is that the framework does not initiate correct when running from the Publisher. Check the security settings so that service account (running QlikView Distribution Service) have full access to the QDF folders. You can also try adding the CalendarGen include file right after 1.Init.qvs, as a work around,

$(Include=$(vG.SubPath)\99.LoadAll.qvs);

Hope this helps

Best regards

Magnus

Not applicable
Author

I've just checked the account that the service runs as and it definitely has access to the folders.

My load script include files currently look like this:

IF '$(vG.BasePath)'= '' then

  let vL.y = ;

  for vL.x =1 to 10-1

  SET vL.y$(vL.x)='..\';

  LET vL.Path='$(vL.y$(vL.x))'&'$(vL.Path_tmp)';

  LET vL.Path_tmp='$(vL.Path)';

  $(Include=$(vL.Path)InitLink.qvs);

  exit for when not '$(vG.BasePath)'= ''

  next

  SET vL.Path = ;

  SET vL.Path_tmp = ;

ENDIF 

$(Include=$(vG.BaseVariablePath)\1.init.qvs);

$(Include=$(vG.SubPath)\7.CalendarGen.qvs);

Is this what you meant? I've also tried replacing the CalendarGen include with the LoadAll include and it is still failing.

I've got a fair few other documents that have the framework loaded in, for getting variables from the variable editor etc, that work with the but this is the only one that is making an explicit function call. Is it possible to put the code in the file into my document to see if I can narrow down the issue?

EDIT: I've just placed the code for the CalendarGen sub into my document with the framework initialisation script, and now the document fails in a different location. It appears to get all the way through the code and fail when attempting to store the calendar into a QVD

EDIT 2: I've tried putting the script for this calendar generation in with an existing document and reloading that through the scheduler. That reloaded successfully and stored the QVD with no issues. So it appears to be when it is in this document that it fails