I am controlling Acrobat from VBA via OLE. The problem is that the background task that is created in task manager is not destroyed when the script ends. In the code below, the task is created and is destroyed.
oPDDoc = ole.Create("AcroExch.PDDoc") oPDDoc.open(pdfin) jso = oPDDoc.getjsobject() ... define some vars
However, if this line is added after ... define some vars
f = jso.addField("reply." +n, "text", vCurrentPage, aRect)
then the background Acrobat task is not destroyed. Is there something I am not cleaning up correctly.? Is there another way I can get rid of this background task?
Oh, and everything works correctly - field is added, etc. It is just background task hanging on. There have been times when that baskground task has prevented other PDFs from opening in the foreground UI until the task is ended. But I don't have specific repeat steps for that.