3 Replies Latest reply on May 27, 2015 1:35 AM by Rebecca Lai

    Failed: Script to save ditamap to FM with ditaval file

    Rebecca Lai

      Hi FM scripting Gurus,


      I'm stuck in the following issue and need help:


      I'm trying to write a script to save ditamaps to composite FM files with ditaval file specified. I use the document property Constants.FS_DitavalFile (=linux.txt) to specify the ditaval file. Unfortunately, it seems that the script does not execute the SaveCompoFm function. If I remove the Constants.FS_DitavalFile property from the function, the script runs properly. I've no idea what the problem is. The following is the SaveCompoFm function. Is there anything wrong with the code? Thanks a lot for your help!


      function SaveCompoFm(file,saveName,ditaval)



          saveProp = GetSaveDefaultParams()



          i = GetPropIndex(saveProp, Constants.FS_FileType)

          saveProp[i].propVal.ival =Constants.FV_SaveFmtCompositeDoc


          i = GetPropIndex(saveProp, Constants.FS_DitavalFile)

          saveProp[i].propVal.ival =ditaval


          retParm = new PropVals()


          return CompoFm;