Stefan Cameron on Forms
Building intelligent forms using Adobe LiveCycle Designer

'Scripting' Category Archive

Auto-Identify Mandatory Fields

I am certain at some point in time you have had to fill-out some type of form on a website and the required fields were identified by an asterisk (*). This is a common way to communicate to a user which fields are mandatory and which ones aren’t.

This is a design pattern that the Form Guide Team adopted when they conceived the default Form Guide user experience. Since the appearance of a field in a form guide doesn’t have to be the same as that of the field in the form (PDF), they were able to automatically add an asterisk next to mandatory fields without affecting their PDF counterparts.

Continue reading…


Posted by Stefan Cameron on March 16th, 2009
Filed under Acrobat,Form Guides,Scripting,Tutorials

Hidden JavaScript Exception Information

In case you missed it, John Brinkman posted a great article on how to extract more information from a JavaScript exception (caught in a try/catch block). Have a look — there’s lots of useful information in the exception object and it’s just a matter of knowing how to expose it. It could save you hours of debugging time!


Posted by Stefan Cameron on March 13th, 2009
Filed under Debugging,Scripting

Expandable Table with Totals

It seems that calculating totals in an expandable table with a dynamic/repeatable row is a hot topic lately so I thought I would post a tutorial on how to build a simple table which represents a purchase order where you can add and remove line items and various totals are automatically calculated.

Before we get started, you’ll need Designer 7.1 and Acrobat/Reader 7.0.5 at minimum to run through this tutorial. I will be using Designer 8.2 and Acrobat/Reader 9.0 to do the tutorial so it’s possible some of the UI may have changed slightly since the 7.1/7.05 versions.

Continue reading…


Posted by Stefan Cameron on February 25th, 2009
Filed under Data Binding,Designer,FormCalc,Scripting,Tables,Tutorials,XFA

Recording of AUC eSeminar on LiveCycle Designer

The recording of the Acrobat User Community eSeminar on Advanced Forms and LiveCycle Designer by Easel Solution’s Angie Okamoto is now available for viewing. Angie demonstrates advanced concepts in creating dynamic forms with LC Designer and you can also see all of the Q&A comment threads between the attendees and the team of specialists answering the questions.


Posted by Stefan Cameron on February 13th, 2009
Filed under Data Binding,Designer,Instance Manager,Scripting,Tables,Tutorials

Careful with Form Compatibility Settings

Let me put it simply: I got burned by using a particular syntax to check the existence of a field inside a subform object due to form compatibility settings in LiveCycle Designer 8.2.

What?

It started with a form I had created using Designer 8.1 which was set to target Acrobat 8.1/XFA 2.6. Later-on, I installed Designer 8.2 and wanted to update my form to target Acrobat 9/XFA 2.8.

In my form, I had a script object with various functions that used the following syntax to test the existence of a field inside a subform object which was passed-in to these functions as a parameter:

if (subformObj.someField)

The result of this was what I expected: If ‘someField’ existed inside ‘subformObj’, the IF statement would evaluate to ‘true’; if it didn’t, it would evaluate to ‘false’. According to the rules of dynamic properties in JavaScript, this was all fine and dandy.

Continue reading…


Posted by Stefan Cameron on February 11th, 2009
Filed under Acrobat,Debugging,Designer,Scripting,XFA