Tuesday, September 27, 2011

Excel import in Form Runner

A pretty neat recent feature of Form Runner is the ability to import data from Excel files. In a few words this allows you to:
  1. upload an Excel file with header and data rows
  2. validate each row against the form's validation rules
  3. import all valid data rows into the persistence layer
As a user you are in control at each step. For example, if your document contains invalid data, you might decide to cancel the import and review your Excel document.

The feature is documented on the Orbeon Forms wiki and is currently available in nightly builds of Orbeon Forms.

For the curious programmer, the implementation is pretty neat and makes use of:
  • Orbeon Forms's XSLT/XPL support to extract the Excel workbook data
  • asynchronous XForms service calls to validate and extract data in the background
  • background XForms to validate and import the data
  • XForms for the user interface
The source code for the feature is available on github.


2 comments:

  1. What about csv import? That would have higher compatibility...

    ReplyDelete
  2. CSV import would be good as well, yes. Waiting for a sponsor at this point.

    ReplyDelete