Portlet Factory, Version 6.1.2


 

Excel Import builder

With the Excel Import builder, you can import into a model the content of a Microsoft Excel workbook. Use this builder when you want to get access to a data store. This builder imports most .XLS formatted files generated by Microsoft Excel. Once imported into the model, Excel file content is transformed into a schema-typed XML document and stored in a variable for easy manipulation and display using the various page-oriented builders such as the Data Page builder.

Note: This builder is not designed for bulk data handling. Do not use a Microsoft Excel file as a primary data source. Use this builder for reporting only.

You must add an Excel workbook to your project before this builder can import it. The project directory in which the Excel file is placed does not matter to the builder. However, the file should be placed under the project's web-inf subdirectory if the file contains data that you do not want exposed in an uncontrolled way.

For example, if the Excel file is placed in a servable content directory, anyone who knows the name and path of the file will be able to download it from the application server with a browser.

 

Quick tips

  • To populate the variable (buildername_Content) with Excel data, call the buildername.getContent method.

    Note: The variable is created automatically by the builder.

  • If the Excel content you need to import is variable in shape, use Automatic in the Content Selection Method input. The builder finds and selects all cells in the smallest rectangular range that includes all the defined content from the chosen workbook sheet. In this way, your Excel workbook can change and those changes are automatically picked up when the builder is regenerated.

  • If the Excel content to import contains a header row, remember to check the Has Header Row input and include this row in the selected range of cells. This allows the builder to generate a more meaningful XML schema describing the imported content.

 

Builder Limitations

Excel Versions Supported

The imported Excel workbook must be in the .XLS format and have been created by Microsoft Excel.

Rich Text

Workbooks that contain rich text cells (those that have multiple fonts and styles) are not supported. Any attempt to import a workbook that has rich text cells throws a runtime exception.

Boolean Formulas

Cells that contain Boolean formulas are not imported correctly. These cells appear in the XML as NaN.

Parent topic: Builder help


Library | Support |