" /> LiveCycle Doc team: November 2009 Archives

« October 2009 | Main

November 23, 2009

LiveCycle ES2 Released!

Read the press release.

We're excited about LiveCycle ES2. We really are. The new features and improvements to existing features make the product a joy to use. Remember using LiveCycle ES to make a form appear in Workspace ES? LiveCycle ES2 makes it easy:

  • One variable type for all form-generated data.

  • Default render and submit services are automatically configured.

  • Prepare Data services can be created to prepopulate forms.

  • New Form wizard adds all the required fields and configures submit buttons.

  • Access to tasks using mobile devices.


I'm not exaggerating - I feel joy when I use LiveCycle ES2. Here are my favorite reasons:

  • Applications provide a framework for developing and packaging solutions.

  • You can create DDX files visually using Workbench ES2.

  • Guides (the next implementation of Form Guides) have their own perspective in Workbench ES2

  • Health Monitor enables you to ensure the LiveCycle ES2 server is running correctly, and helps troubleshoot problems.

  • Wizards. Lots of wizards in Workbench ES2 make creating new assets easier and faster.

  • Application modeling technology enables you to create a common data structure that integrates Flex applications, Guides, forms, and processes.

  • You can easily assign tasks to multiple users simultaneously - useful for reviewing documents by committee.


I'll stop there on advice from my editor (who doesn't like long lists) but believe me I could go on. You can read the What's New guide for more information.

To see all the great new product content that we've produced so far, see the Documentation tab on the LiveCycle Development Center. As usual, you can comment on the HTML pages of the product documentation.

November 13, 2009

Changing the fill color of a field based on a condition

It is easy to change the fill color of a field based on a condition, such as when a number exceeds a certain amount. For example, the script (JavaScript) below changes the fill color of a field to yellow when the value is below 100 and red when the value is 100 and up.

Try it
1) From LiveCycle Designer, open the "Dynamic Purchase Order" sample form (Purchase Order Dynamic.xdp).
2) Select the Quantity field (numQty).
3) Select and the "exit" event if a user will be entering data in the field or select the "initialize" event when the field is populated with data.
4) Copy and paste the following script into the Script Editor and edit the fill color to suit your purpose. If you would like the fill color to change for both user entered data and populated data, copy and paste the script into both the "exit" and "initialize" events.

if (this.rawValue >= 100) //red
{
this.fillColor = "255,0,0";
}
else
this.fillColor = "255,255,0"; //yellow

5) Test the script using the Preview PDF tab.

Tips
Use a numeric field with this script.
Make sure that you select JavaScript and run at the client.
Make sure that the "Preview Adobe XML Form As" property (in Form Properties) is set to "Dynamic XML Form".
Use the "initialize" event to make the fill color change when the form is populated with data.
Use the "exit" event to make the fill color change when a user enters data.

For more LiveCycle Designer scripting samples, visit the LiveCycle Developer Center at http://www.adobe.com/devnet/livecycle/designer_scripting_samples.html/.

November 5, 2009

Should I use the Output service or Forms service?

Recently, when I was automating a process, part of the requirement was to merge XML data with a form design that was created in Adobe LiveCycle Designer ES. When you are merging a form design with data from an XML file, you can use either the Forms service or Output service in LiveCycle ES. Depending on how you use the resultant merged form design and data, determines which service best meets your requirements.

If you are merging multiple sets of XML data to create filled forms, use the Output service. For example, if I wanted to create PDF output that could not be modified (non-interactive) for electronic archival, it is best to use the Output service. In addition, I noticed that the Output service was also useful for creating different types of printed output, such as Postscript and would be useful if I needed to print the output. In summary, use the Output service when you require these features:


  • Batch processing or merging one or more records with a form design to create multiple documents.

  • Specifying different print formats and label printers.
  • Controlling of printer settings, such as stapling, label printers, collating, and so on.

  • Using pattern matching to specify different form designs to merge with the data with.

  • Creating a filled and non-interactive PDF file that is useful for archiving.

  • Sending the output to a printer.

If you are merging XML data with a form design where the merged output is used by people, such as an PDF form for an approval process, use the Forms service. For example, if I wanted to merge XML data with a form design to create a PDF form, that PDF form would be an interactive form that could be displayed to person. That person could add data to the form and perhaps click a button so that the form could be handled electronically. In summary, use the Forms services when you require these features:


  • Using form design scripts to transform the appearance of the form, perform calculations, and dynamically generate or retrieve data.

  • Providing mechanisms to render file attachments and to other formats, such as HTML or form guides (8.2).

  • Handling electronic form submissions.

  • Providing mechanisms to pre-populate a form with data.

Hopefully I have whet you appetite with some of the features that the Output and Forms services provide. If you find that you have similar needs in your process, check out the Output service and Forms service sections in LiveCycle ES Services guide for more detailed information.