I get this error message when trying to detach a 123 spreadsheet from a document to the servers hard drive. It works fine if I run the agent locally but when I run it scheduled from the server… I get this error. I have myself set under the run unrestricted methods and operations. I am also set to run restricted…
Here is a sample of my code.
Set fileObject = doc.GETFIRSTITEM(“spreadsheet”) ’ fname.Type = ATTACHMENT
If (fileObject.Type = RICHTEXT) Then
Forall o In fileObject.EmbeddedObjects
If ( o.Type = EMBED_ATTACHMENT) Then
FileExtractName = o.Source
gBidNumber = Trim(Left(FileExtractName,9))
Call o.ExtractFile("c:\samples\" & o.Source)
Call o.Remove
Call doc.Save(False, True)
End If
End Forall
Endif
What is wrong here?