Navigation:  WebOffice APIs > WebOffice Script API >

Generate a Weboffice ePaper report via Script API

Previous pageReturn to chapter overviewNext page

It is possible to generate WebOffice ePaper reports via the WebOffice 10 R3 Script API function by using the function scriptAPI.generateEPaper( aObjectIds, sEPaperId, sEPaperFormat, sEPaperName, oDynFields, iDpiCount, bSuppressCopyright, bNoDocumentDisplay )

 

The following parameters will be used by the function:

Mandatory

aObjectIds (string/array)
the unique feature id(s); pass either multiple values delimited by semicolon or an array of multiple object ids

sEPaperId (string)
the name of the configured WebOffice ePaper report

Optional

aEPaperFormat (string)
the format of the output document, possible values are PDF|XLSX|DOCX|RTF|ODT, any other string or null uses the WebOffice configuration value

sEPaperName (string)
the name of the generated WebOffice ePaper document; pass null if the WebOffice 10 R3 default naming convention should be used

 

Note: WebOffice ePaper reports can also be archived. See chapter Common Settings for configuration details. If you assign a name (sEPaperName) for your report via Script API, then an already existing document with this name in the archive will be overwritten. If no name is assigned, the creation time and user name will be used (zB YYYYMMDD_HHMMSS_USER.pdf).

 

oDynFields (object)
javascript object holding dynamic field ids and value in the form oDynFields = { fieldId1: fieldValue1, fieldId2, fieldValue2, ... }; pass null if no dynamic fields are available or should be set

 

Note: The function supports the dynamic fields (no captions): title_value, orgname_value, orgadr_value, creator_value, createdat_value, disclaimer_value. For the date field various formats are accepted.

 

iDpiCount (integer)
the resolution of the WebOffice ePaper report document: only used for reports of type PDF; pass null to use the WebOffice 10 R3 configuration value

bSuppressCopyright (boolean)
set "true" if embedded maps are not to show copyright information

 

Note: Since each WebOffice ePaper report is connected to a WebOffice 10 R3 layer no layer ID has to be set.

Note: Currently scale and map views cannot be defined in the WebOffice 10 R3 Script API but they may be configured in the project configuration.

Note: A valid WebOffice ePaper template must be configured in WebOffice author! If more than one template configured in WebOffice author relates to the same .mrt file, the first configuration will be considered.

 

WebOffice ePaper generated with custom tool using the WebOffice 10 R3 Script API

WebOffice ePaper generated with custom tool using the WebOffice 10 R3 Script API