1 Reply Latest reply on Jul 31, 2014 11:01 AM by David Bush

    xpsplugin.exe holding onto .docm files

    David Bush

      I just finished making some minor updates to an ECR workflow and, in the process, updated the ECR word document from a .doc file to .docm to take advantage of some of the shiny new buttons and such.


      In our workflow, there are certain ECR's that come in as a child to an existing ECR. In those cases, the API will check out the parent, set a few variables, paste the new child ECR as reference to the existing parent ECR and then check in the parent.


      oEnumVar = oParentFile.GetEnumeratorVariable

      oEnumVar.SetVar("ECRType""", fSelForm.ComboBox_ECRType.SelectedItem)



      'paste child ECR as reference to parent ECR

      Dim refParentFile As IEdmEnumeratorCustomReference6 = oParentFile

      refParentFile.AddReference(oDestFile.ID, oDestFolder.ID)


      'check in parent ECR

      oParentFile.UnlockFile(0, oUser.FullName + " added new child " + fSelForm.sChildECRNumber)


      What has me stumped is that API started giving me the error "An attempt was made to access a file that is exclusively opened by another application" if the parent file is a .docm. It doesn't give me this error if the parent is a .doc file and it doesn't matter what the child is. I have found that the error occurs on:




      and only happens if the SetVar() command has been run on the file. It does not give an error if only the GetVar() command is run. Once the program errors out, I cannot check the file back in unless I kill the xpsplugin.exe process first.


      I'm at a complete loss here and would love any ideas. I've tried doing a ClearLocalCache and doing an explicit Flush(), but nothing helps.