I am using acrobat XI I have tried output a text file like this
var cMyC = \"abc\";
var doc = this.createDataObject({cName: \"test.txt\", cValue: cMyC});
this.e
Impossible. For security reasons, saving a file automatically is not allowed.
As stated in the SDK:
Beginning with Acrobat 6.0, if the parameter cDIPath is non-null, a NotAllowedError exception is thrown and the method fails.
If cDIPath is not passed to this method, a file selection dialog box opens to allow the user to select a save path for the embedded data object.