Stefan Cameron on Forms
Building intelligent forms using Adobe LiveCycle Designer

'Scripting' Category Archive

PDF Forms Bible Review

PDF Forms Using Acrobat and LiveCycle Designer Bible

Last February, I announced the release of a new Designer book titled, “PDF Forms Using Acrobat and LiveCycle Designer Bible”.

Over the past few months, I had the opportunity to review it and I thought I would share my comments, with respect to the second-half of the book, which deals with LiveCycle Designer ES and XFA forms, to help you decide if it would be a good book for you*. (The first-half deals with authoring PDF forms, a.k.a. AcroForms, in Acrobat and is beyond the scope of my blog.)


  • explains the licensing agreement involved when enabling forms for Reader using Acrobat’s “Extend Features in Adobe Reader” feature (p. 268) — this is a frequently-used feature however its governing licensing agreement, seldom understood, is explained here in “plain English”;
  • presents and reasons through different design approaches for a particular solution, helping the reader make an informed decision on the best course of action;
  • anything and everything you could possibly want to know is dealt with in some way;
  • lots of important, time-saving insights in the inline ‘notes’;
  • something for everyone from beginner to advanced;
  • many cross-references between various topics, making it very easy to start in any chapter and still find all the information you need.


  • risk of “information overload” — use this book as reference since it’s not a light read, though their goal is simply to present a myriad of options and let you pick the one that best suits your needs.

Overview of Topics Covered:

  • all about tables (from simple layouts to advanced);
  • data merging with bindings;
  • Designer user interface details and lots of tips and tricks for accelerating form layout tasks;
  • working with static forms (with PDF backgrounds) and dynamic forms, highlighting the differences;
  • great details on all sorts of pagination options;
  • lots of detail on JavaScript and FormCalc, good scripting exercises with explanations, debugging tips, table with JavaScript and equivalent FormCalc functions to make it easy to script in either language if the other is more familiar to you;
  • form deployment options;
  • when and how to use data connections in your forms (XML, schema, database, web service) and setting data bindings;
  • great overview of LiveCycle ES, its components (e.g. LC Forms, LC Reader Extensions, LC Rights Management, LC Content Services, etc.) and what they do.

This book is available now on and and elsewhere.

* Please note that these opinions are not necessarily those of Adobe Systems Incorporated.

Posted by Stefan Cameron on November 13th, 2009
Filed under Acrobat,Books,Data Binding,Designer,Instance Manager,Scripting,Tables,XFA

Designer ES2 Scripting Reference

This is one of the references I find the most useful when writing scripts and it’s now available for Designer ES2.

What’s more, you can now find all of the ES2 Developer and Programmer documentation all in a single place just like all ES2 documentation (which includes the Dev and Prog docs from the former link). Great sites to bookmark and nice to finally have it all in one spot!

This all comes to you due to the recent LiveCycle Developer Center site refresh in conjunction with the recent release of LiveCycle ES2. Check it out!

Posted by Stefan Cameron on November 12th, 2009
Filed under Designer,LiveCycle,Scripting

Multi-Selection List Schema Definition

After spending some time, recently, showing you how to connect your form to a schema and highlighting Designer’s support for schema metadata, I thought I would round-off my current train of thought on schemas by tackling multi-selection listboxes. Since they store their selected data in <value> nodes, once you think about it, their schema definition may not be obvious. When you’re working with XML data that isn’t governed by a schema and namespaces, it is perhaps easier to work with (i.e. accept) these <value> nodes however things change when you have a schema telling you how your data must be structured and scoped (with namespaces).

Continue reading…

Posted by Stefan Cameron on September 30th, 2009
Filed under Acrobat,Bugs,Data Binding,Scripting,Tutorials,XFA

Schema Metadata

My first tutorial on XML schemas explained how to connect your form to a schema however it did not show some of the Data View palette’s special features with respect to metadata in XML schemas.

Using metadata based on a combination of the XML Schema appInfo and Dublin Core title and description elements, you can influence how the Data Connection Wizard creates fields you drag and drop from the data connection tree into your form. You can also direct the Data View palette to show some of this information in the Schema Data Connection Tree that it displays.

Continue reading…

Posted by Stefan Cameron on August 28th, 2009
Filed under Data Binding,Designer,Scripting,Tutorials,XFA

Tip: Pretty XML Strings

I regularly use the saveXML() method, available on all node class-based objects, as a way to debug my forms (think of it as a type of introspection technique). The method outputs a string representation of the XML content of the node in question, which helps when attempting to discover the underlying object structure without a debugger…

For example, say you have a simple form with a text field and a numeric field. The following statement will output the form’s data to the JavaScript Console in Acrobat:


The result, however, isn’t very readable:

<?xml version="1.0" encoding="UTF-8"?>
<xfa:data xmlns:xfa=""

Though I had been using saveXML() for quite some time, I hadn’t realized that it actually takes an optional parameter, a string with a value of “pretty”, that results in much nicer output.


results in the following pretty/readable output:

<?xml version="1.0" encoding="UTF-8"?>
<xfa:data xmlns:xfa="">

Posted by Stefan Cameron on August 19th, 2009
Filed under Debugging,Scripting,Tips