I created a simple form based on a tab delimited text file. The form has 2 input fields "Task" and "Level_Required".
I simply just want to load the values from the text file into these fields when I click a button.
My button "mouseUp" event looks like this:
event.target.importTextData("tasks.txt",0);
var task = this.getField("Task");
var lr = this.getField("Level_Required");
this.frmTasks.Task[0] = task.value;
this.frmTasks.Level_Required[0] = lr.value;
When I run it the debugger comes back with:
Acrobat JavaScript Debugger Functions Version 9.0
Acrobat EScript Built-in Functions Version 9.0
Acrobat Annotations / Collaboration Built-in Functions Version 9.0
Acrobat Annotations / Collaboration Built-in Wizard Functions Version 9.0
Acrobat SOAP 9.0
Exception in line 1 of function top_level, script XFA:frmProgressCard[0]:frmTasks[0]:cmdLoadLists[0]:mouseUp
Can anyone shed some light on this for me?
c:\program files\adobe\acrobat 9.0\acrobat\javascripts\config.js
TrustedImportTextData = app.trustedFunction( function ( oDoc, fileName, row ) {
app.beginPriv();
var Result = oDoc.importTextData(fileName, row);
app.endPriv();
return Result;
});
Now if I could only get the "getField" to work!