I have the following Script Callback:
case CB_AFTERWRITECOM
Dim tmpnam as string
tmpnam = stats.filename
stats.filename = “C:"+stats.expdoc.universalid+”.doc"
'**** SaveWordDoc ( FILE, PROTECTDOC, SAVETEMPORARY, FORCERANDOM ) ****
Call export.SaveWordDoc ( stats, True, False, False )
stats.filename = tmpnam
If I select more than one document, the code will only save the first document as a word file to the C drive. This file is also write protected.
If I use the following code I get a different result:
case CB_AFTERWRITECOM
stats.filename = “C:"+stats.expdoc.universalid+”.doc"
'**** SaveWordDoc ( FILE, PROTECTDOC, SAVETEMPORARY, FORCERANDOM ) ****
Call export.SaveWordDoc ( stats, True, False, False )
If I select more than one document, the code will save a word file to the C drive for every selected document. However these files aren’t write protected.
I’m really confused at this point. This is the only piece I need and I’m good to go. I need to save a protected file to the server for every document sent. Wondering if it has something to do with setting the filename back.
Thanks in advance for your help.