Adobe Reader Javascript Open .DOC
Copy link to clipboard
Copied
I just tried to many code from internet to open automatically .doc which are attached in PDF but i get this : "Cannot open type of application/msword"
I tried this:
var oDoc = openDataObject("image.doc"); console.println(oDoc.path);
I tried to find another function which are specify the type of the document and to can open it in Microsoft Word!
Regards
Copy link to clipboard
Copied
Seems clear from the documentation that this method is only for PDF. I am inclined to agree that there is no method to do what you want; even automatic extraction has been blocked for a decade. But you may be able to extract the attachment, prompting the user for the location, and have it automatically launch, if that function still works.
Copy link to clipboard
Copied
I have done it the
this.exportDataObject({ cName: "image.doc", nLaunch: 0 }); and is exported for the user but I cannot launch automatically because I cannot find the javascript command to launch it!
Copy link to clipboard
Copied
Why nLaunch:0 ?
Copy link to clipboard
Copied
Because if I use nLaunch:1 or nLaunch:2 nothing happend...
Copy link to clipboard
Copied
nLaunch: 2 should work, even for non-PDF files, although the user will be presented with a security warning.
Copy link to clipboard
Copied
Since the documentation says that 0 means DO NOT LAUNCH, that at least is expected.
Copy link to clipboard
Copied
I know but as I told you I have used 1 and 2 but are not opening it I get only this error: " Cannot open this file type application/msword"
Copy link to clipboard
Copied
Can you open the attachment manually in Adobe Acrobat?
Copy link to clipboard
Copied
Yes manually I can open it, but if I use nLaunch: 1 and nLaunch: 2 I get that error is not opening!
Copy link to clipboard
Copied
Well, it is the weekend now. But Photoshop 6.0 doesn't need activation. Do you mean Photoshop CS6?
Copy link to clipboard
Copied
Wrong thread?
Copy link to clipboard
Copied
Sorry, wrong message. Actually you never said that options 1 and 2 gave this error. You said specifically that openDataObject gave the error.
Still, if you get an error, why would you try to fix it by using an option which is clearly documented as NOT doing what you want?

