Avatar

Level 10

Hi,

I guess it is too late now, but you can do this in a LiveCycle Designer form.  Just the same as an Acrobat form, except you refer to the Doc object as event.target.  So to attach a file use this JavaScript;

if (event.target.importDataObject("MyAttachedFile"))

{

    var attachmentObject = event.target.getDataObject("MyAttachedFile");

    console.println("Attachment path="+attachmentObject.path);

}

And, this will open it.

event.target.exportDataObject({ cName: "MyAttachedFile", nLaunch: 2 });

Bruce