-
-
-
User Guide Version 2022.1.2 Last Revision: 2022-06-01 Upland Objectif Lune 2030 Pie-IX, Suite 500 Montréal, QC, Canada, H1V 2C8 +1 (514) 875-5863 www.objectiflune.com All trademarks displayed are the property of their respective owners. © Upland Objectif Lune. 1994-2022. All rights reserved. No part of this documentation may be reproduced, transmitted or distributed outside of Upland Objectif Lune by any means whatsoever without the express written permission of Upland Objectif Lune.
-
Table of Contents Table of Contents 4 Welcome to PlanetPress Connect 2022.
-
Minor font changes Uninstalling General information 112 123 126 Connect: a peek under the hood The Workflow server The Connect server The Connect database The File Store The engines The REST API Log files Location Name Format Connect file types OL Connect projects 126 127 128 129 129 130 130 131 131 132 132 133 135 Automation with Workflow Using the REST API Versioned Projects Versioned Projects Creating Versioned Projects Viewing Project History Viewing Project Content Sample Projects Versioned Project
-
Email processes with OL Connect tasks Print processes with OL Connect tasks Web processes with OL Connect tasks Batching and commingling OL Connect automation with Node-RED Installation OL Connect nodes Connection settings for OL Connect Server OL Connect resources in Node-RED Flows in an OL Connect application Node-RED: nodes and common techniques Nodes used in OL Connect flows Reading a JSON file Parsing a JSON string Using variables Setting and moving msg properties Iterating over items in an array Conca
-
Processing received data The DataMapper DataMapper basics Data mapping configurations Creating a new data mapping configuration Opening a data mapping configuration Saving a data mapping configuration Down-saving a data mapping configuration Using the wizard for CSV and Excel files Using the wizard for databases Using the wizard for JSON files Using the wizard for PDF/VT or AFP files Using the wizard for XML files Advanced PCL to PDF options Data mapping workflow Creating a data mapping workflow Testing the
-
Using scripts in the DataMapper Setting boundaries using JavaScript Objects Example Example Functions The Designer Designer basics Features Templates Contexts Sections Print Creating a Print template with a Wizard Print context Print sections Pages Master Pages Media Email Designing an Email template Creating an Email template with a Wizard Email context Email templates Email header settings Email attachments Web Creating a Web template with a Wizard Web Context Web pages Forms Using Form elements Using Jav
-
Sending the template to the Workflow tool Receiving and extracting data from a COTG Form Using COTG data in a template Designing a COTG Template Capture OnTheGo template wizards Using Foundation COTG Elements Using COTG Elements Testing a Capture OnTheGo Template Using the COTG plugin Dynamically adding COTG widgets Saving and restoring custom data and widgets Using submitted COTG data in a template Capture OnTheGo API Content elements Element types Editing HTML Attributes Inserting an element Selecting an
-
Editing a snippet Renaming a snippet Translating a snippet HTML snippets JSON snippets Handlebars templates Styling and formatting Local formatting versus style sheets Layout properties Styling templates with CSS files Styling text and paragraphs How to position elements Rotating elements Styling a table Styling an image Background color and/or image Border Colors Fonts Locale Spacing Personalizing content Variable data Conditional content Dynamic images and Print section backgrounds Dynamic tables Snippets
-
Preferences General preferences Clean-up Service preferences DataMapper preferences Database Connection preferences Editing preferences Email preferences Emmet preferences Engines preferences Hardware for Digital Signing preferences Language preferences Logging preferences Parallel Processing preferences Print preferences Sample Projects preferences Save preferences Scripting preferences Servers preferences Versioning preferences Web preferences Writing your own scripts Script types Creating a new Standard
-
Translating a template Tagging elements for translation Pluralization Exporting and importing translation files Designer User Interface Dialogs Keyboard shortcuts Menus Panes Toolbars Welcome Screen Print options Job Creation Presets Wizard Output Creation Presets Wizard Designer Script API Standard Script API Functions and fields Example Functions and fields html() 994 994 998 999 1001 1002 1100 1106 1118 1143 1149 1150 1230 1246 1341 1343 1370 1371 1371 1372 html() html(value) margins 1372 1372 1373 F
-
Print settings in a template Aborting content creation Print using standard print output settings Print Presets Print using Advanced Printer Wizard Adding print output Models to the Print Wizard Splitting printing into more than one file Print output variables Generating Fax output Generating Tags for Image output Generating Email output Before generating Email output Testing Email output Generating Email output from Connect Designer Generating Email output from Workflow Aborting content creation Using an E
-
Workflow 2022.1 Improvements OL Connect 2022.1 Improvements Known Issues Previous Releases OL PlanetPress Connect Release Notes 2021.2.1 OL PlanetPress Connect Release Notes 2021.1 OL PlanetPress ConnectRelease Notes 2020.2.1 OL PlanetPress Connect Release Notes 2020.1 OL PlanetPress Connect Release Notes 2019.2 OL PlanetPress Connect Release Notes 2019.1 PlanetPress Connect Release Notes 2018.2.1 PlanetPress Connect Release Notes 2018.1.6 PlanetPress Connect Release Notes 1.
-
Welcome to PlanetPress Connect 2022.1 Note Since we are always looking for new ways to make your life easier, we welcome your questions and comments about our products and documentation. Use the feedback tool at the bottom of the page or shoot us an email at doc@ca.objectiflune.com. PlanetPress Connect is a series of tools designed to optimize and automate customer communications management. They work together to improve the creation, distribution, interaction and maintenance of your communications.
-
Setup And Configuration This chapter describes the PlanetPress Connect installation and the different considerations that are important in regards to the installation and use of PlanetPress Connect. l "System and Hardware Considerations" below l "Installation and Activation" on page 32 l "Known Issues" on page 111 l "Server Configuration Settings" on page 89 l "Uninstalling" on page 123 System and Hardware Considerations There are a variety of considerations to be aware of.
-
Directories and folders All Connect applications are installed under an arbitrarily selectable main folder. If the default installation folder options were used, this installation folder would be %PROGRAMFILES%\Objectif Lune\OL Connect. The installation folder will hold all the executable files and other files and folders required for the operation of the whole product suite. All these files and folders remain static after installation.
-
Working folders Working folders for Connect are created and used on a per-user-basis under the respective user's profile folder, accessible on Windows with the standardized system variable %USERPROFILE% in the subfolder "Connect". Working folders are: l l l l %USERPROFILE%\Connect\filestore: This folder will hold non-intermediate files for the operation of Connect. Files in this folder will be used frequently, but not with a high frequency.
-
Database Considerations This page describes the different considerations and pre-requisites for the database back-end used by PlanetPress Connect, whether using the MariaDB instance provided by the installer, or pre-existing (external) instance. Using the MariaDB Instance from the Installer The MariaDB Instance provided in the "Installation Wizard" on page 37 is already preconfigured with options to provide the most stable back-end setup.
-
pre-existing (External) database then you yourself must ensure that the External database is accessible to Connect. Upland Objectif Lune will take no responsibility for setting up database connections to any but the supplied MariaDB database. Options available within the installer: l l l The Configuration page for the local MySQL is displayed. MySQL settings are pre-filled with default values if no existing MySQL database configuration is found.
-
l l l When MS SQL is selected, the default values for root user are sa and 1433 for the port. If database settings from a previous OL Connect installation are found, the pre-exising settings will be displayed for the matching database type. For MS SQL settings, this will only work if they were created with Server Config Tool 1.5.0 or later, or the Installer for OL Connect 1.6.0 or later.
-
4. Counter check that everything is working properly with Microsoft SQL. 5. Open a command-line prompt with full administration rights. 6. Enter the command sc config OLConnect_Server depend= /. This removes the dependency. Please be aware: The key word depend must be followed immediately by the equal sign, but between the equal sign and the forward slash there must be a space. Additional information can be found here: http://serverfault.com/questions/24821. 7.
-
Warning Copying (duplicating) a Virtual Machine with Connect installed and using both images simultaneously constitutes an infringement of our End-User License Agreement. Note While some virtual machine environments (from VMWare and Microsoft) are supported, other virtual environments (such as Parallels, Xen and others) are not supported at this time. Remote Desktop Support Tests have demonstrated that PlanetPress Connect can be used through Remote Desktop.
-
l Click on Start, Run. l Type in services.msc and click OK. l Locate the Windows Search service and double-click on it. l Change the Startup Type to Disable, and click Stop to stop the service. l Try the installation again. l Once complete, you may re-enable the service and start it. Commandline switches and .ini entries PlanetPress Connect is intended to work stably and reliably, based on Java and the Eclipse framework.
-
l Portuguese l Chinese (Simplified) l Chinese (Traditional) l Japanese. The default language is English. The PlanetPress Connect help system (this document and the online help) is currently only available in English and (for the biggest part) in French. l Encoding: l Issues can sometimes be encountered in menus and templates when running PlanetPress Connect on a non-English operating system. These are due to encoding issues and will be addressed in a later release.
-
NodeJS Server NodeJS HTTPS Server Listens on port # 9090 Destination port # Comment TCP 8443 TCP 25, or 587 when SMTP Input plugin encryption is enabled Email Input plugin 110 Secure Email Input 993 plugin Send Email plugin 25 Secure Email Output plugin LPR LPD Telnet FTP Input/Output MySQL Microsoft SQL Server HyperSQL Type TCP TCP TCP TCP 587 TCP 515 3306 TCP TCP TCP TCP TCP+UDP 1433 TCP+UDP 9001 TCP 515 9100 21 Default POP3 port Default SMTP port l Port numbers in bold type are use
-
performance from PlanetPress Connect and they give a rough indication when it would be useful to start looking into hardware upgrades or extra PlanetPress Connect Performance Packs. Performance analysis details Connect's output speed is limited to a certain number of output items (web pages, emails, or printed pages) per minute. What the maximum total output speed will be is determined by your licence and any additional Performance Packs you might have (see "Speed quota: Pages Per Minute" on page 95).
-
A DataMapper engine extracts data from a data file. A Merge engine merges the template and the data to create Email and Web output, or to create an intermediary file for Printed output. The intermediary file is in turn used by a Weaver engine to prepare the Print output. Configuring these engines to match both the hardware configuration and the typical usage situation is probably the most effective way to improve Connect's performance.
-
in this topic). l l l l l l Antivirus exclusions. Sometimes, virus scanners, other security software or indexing services can interfere. It can help to disable those kinds of tools for the areas where Connect stores intermediate files. You could exclude the entire C:\Users\\Connect folder. See also: "Antivirus Exclusions" on page 16. Use a high-performance, low-latency hard drive. Connect benefits from fast I/O.
-
Note PlanetPress Connect 2022.1 is expected to run on some older operating systems, but just as Microsoft no longer supports these older operating systems, Upland Objectif Lune will not provide support for PlanetPress Connect products running on them. The historic operating systems that it is expected PlanetPress Connect 2022.1 will continue to run on include: Microsoft Windows 7; Microsoft Windows 2003 Server; and Microsoft Windows 2008 Server R2. Virtual Environments l VMWare/VSphere l Hyper-V (8.
-
most likely to produce expected results for most implementations. You should, however, keep in mind that it may not represent the optimal setup for your particular application. For more information and tips about performance considerations, see "Performance considerations" on page 26.
-
Editions of Connect Products There are three editions of OL Connect: PrintShop Mail Connect, PlanetPress Connect and PReS Connect. While all three editions share common modules, they are generally not used for the same purposes. Technically speaking, their hardware requirements would therefore be the same but in practice, PReS Connect is likely to require higher-end hardware while PrintShop Mail Connect will generally require less power to achieve expected results.
-
l If you are a Reseller, the installers can be downloaded from the Objectif Lune Partner Portal site (https://extranet.objectiflune.com/) or through the OL Update Manager if it is activated.
-
l In order to use the automation features in Version 2022.1, PlanetPress Workflow 2022.1 will need to be installed. This can be installed on the same machine as an existing PlanetPress® Suite 7.x installation or on a new computer. For more information, please see "Information about PlanetPress Workflow" on page 65. If Workflow installation finds that .NET 4.0 is not already installed, it will install that version as part of the setup process.
-
Permissions for PlanetPress Connect Server The PlanetPress Connect Server module, used by the Automation module, requires some special permissions to run. These permissions are set during installation, in the Engine Configuration portion of the "Installation Wizard" on page 37, but it can also be configured later by modifying permissions for the service. To do this: l l l l In Windows, open the Control Panel, Administrative Tools, then Services (this may depend on your operating system).
-
Updating Connect Updating to Connect 2019.1 from earlier Connect version In order to update PlanetPress Connect to 2019.1 it is first necessary to update the Connect License. For details on how to upgrade the Connect License offline see the Upgrading Connect on machines with no internet access section in the document.
-
signature, but also usually checks if the certificate itself is still valid. That check is done against the current Certificate Revocation List (CRL), which needs to be retrieved from the internet. However, if the machine in question does not have internet access, the retrieval of the CRL must fail, which will lead to subsequent validation issues. To circumvent such issues it is highly recommended to switch off the CRL retrieval prior to installing Connect on machines without internet access.
-
Note Note that PlanetPress Connect requires prior installation of Microsoft .NET Framework 4.5. For a full list of other prerequisites, see "Installation prerequisites" on page 33. Running the Installation with extra logging The installer can be run with enhanced logging options, if needed. To do so, run the PlanetPress_Connect_Setup_x64.exe from the command line with one of the following command line options: l PlanetPress_Connect_Setup_x64.
-
Component Selection After clicking the Next button, the Component Selection page appears, in which the different components of PlanetPress Connect can be selected for installation. The options are: l l Base: The installation files required for any PlanetPress Connect Connect installation. This component is not optional. Designer: The Designer module (see "The Designer" on page 475) can be installed standalone (with no other installed modules) on as many machines as you like.
-
Upland Objectif Lune will take no responsibility for setting up database connections to any but the supplied MariaDB database. See "Database Considerations" on page 19 for more information about setting up external databases. l Destination folder: This is the location where Connect components are to be installed. Use the Browse button to navigate to a folder other than the default, if required. Note The installation path cannot contain any non ASCII characters (such as Asian language Unicode characters).
-
Note The Windows user account must have access rights to all local and network resources required for production, as well as Windows "Log on as a Service" rights. The Windows user account selection entered here should be recorded for future use, as the "Security and Users Settings" on page 92 dialog can only ever be executed through the user account specified on this page. l l Account: The Windows user account that the service uses to login. If the machine is within a domain, use the format domain\userna
-
l l User: Enter the internal username for connection to the OL Connect Server. The default username for new installations is olc-user. Password: The password associated with the selected user. Use the eye icon to toggle between displaying or masking the password entry. The password is not validated for password strength, so any entry is acceptable. Note that prior to PlanetPress Connect version 2020.2, only one user account could be configured on a Connect Server.
-
l a lower case character (a, b, c ... ) l an upper case character (A, B, C ...) l a numeric digit (1, 2, 3 ...) l a punctuation character (@, $, ~ ...) For example: "This1s@K" Note When updating from an earlier Connect version, the appropriate MariaDB password must be entered or the update will fail. If the password is subsequently forgotten, then MariaDB must be uninstalled and its database deleted from disk before attempting to reinstall.
-
Use the eye icon to toggle between displaying or masking the password entry. The password is not validated for password strength, so any entry is acceptable. Configuring External Database Connection The Database Connection page appears if the supplied MariaDB module was not selected for installation. This page is for setting up the connection to an existing External database. l l l l l l System: Select the database type to use for thePlanetPress Connect Engine.
-
Server to accept SSL connections. This must be done prior to the installation of Connect. By default, the connection will not verify the server certificate (verifyServerCertificate=false), which would allow connecting to a server using a self-signed certificate.
-
The Product Update Manager If the Configure Update Check option has been selected, a message will be displayed after clicking “Finish” in the setup. The message details the information that needs to be sent back to Upland Objectif Lune in order to determine when/if the software needs updating. Click “Yes” to install or open the Product Update Manager where the frequency with which the updates can be checked and a proxy server (if required) can be specified.
-
General information PlanetPress Connect can be installed from the command line in "silent mode" to allow for scenarios such automated installations during company wide roll-outs, or to allow for unattended out-of-hours updates. The trigger for the Connect Installer to run in silent mode is a text file with the fixed name installProperties.ini located in the same folder as the PlanetPress Connect installation executable file. How to prepare the installProperties.
-
If set to false, standard logging is done. l path: String (Default: %PROGRAMDATA%\Objectif Lune\Installation Logs) Sets the folder to which the installation log will be written. Only the log folder should be specified here, not the log file name. Note The log file name's format is set automatically and uses the format Installer-YYYYMM-DD-####.#.#.log, where: l YYYY-MM-DD = The date the log was created l ####.#.
-
l l l l product.MariaDB l product.Messenger path: String (Default: %PROGRAMFILES%\Objectif Lune\OL Connect) Sets the installation root folder for the PlanetPress Connect applications. RegisterService.connectServer: Boolean (Default: true) Register the Server services or not (such as in the case of a container). server.username: String (Default: the current user/domain installing the service) Determines the domain and username to be used when configuring the Server service.
-
l l l l l l l l l l l l l This setting is optional. Otherwise it is required. l The value is required to be mariadb, if the value is to be provided. database.host: String, Optional (Default: there is no default for this setting) If product.MariaDB = True has been set, this value is required to be set to localhost, if provided. database.port: Numeric, Optional (Default: default is MariaDB's default port, 3306) The database engine port.
-
; Installation settings [Installation] product.Designer = true product.Server = true product.PrintManager = true product.ServerExtension = false product.MariaDB = true product.Messenger = true RegisterService.connectServer = true server.username = Administrator server.password = ObjLune server.connection.user = olc-user server.connection.password = secret database.rootpassword = @Admin2022 database.username = olconnect database.password = @Admin2022 database.remoteaccess = true path = "c:\Program Files\Obje
-
Allows the user to specify if they wish to keep or remove user data (located under %PROGRAMDATA%\Objectif Lune\OL Connect when performing a product uninstall. Example: ; Uninstallation/Repair properties [Uninstall] remove = true keepdata = true Properties file examples Simple Connect installation example Here is an example of a complete installProperties.ini file for a relatively simple PlanetPress Connect installation.
-
[Uninstall] remove = true keepdata = false Exit Codes Success l 0 = Installation completed successfully / no specific error code was returned.
-
Upgrade errors (400s) l l l l 401: Some Connect applications were running and need to be closed before installation can proceed. 402: The installer brand does not match the brand of the OL Connect version currently installed. (PlanetPress) 403: The installer brand does not match the brand of the OL Connect version currently installed. (PReS) 404: The installer brand does not match the brand of the OL Connect version currently installed.
-
applications. This allows time for reviewing the applications and for organizing a commercial license. If a modification to the trail license is required, such as to allow an extension to the trial period, or for extra functionality, then a new activation code will need to be requested. Obtaining the PlanetPress Connect Magic Number To obtain an activation file the OL™ Magic Number must first be retrieved.
-
l l l l l l License: This box displays the EULA. Please note that this agreement is legally binding. I agree: Select to accept the EULA. This option must be selected to install the license. I don't agree: Select if you do not accept the EULA. You cannot install the license if this option is selected. Load License File: Click to browse to the Connect license file (.olconnectlicense), once it has been received.
-
Workflow components. l If you have both PlanetPress Workflow and PlanetPress Connect installed, it will not be possible to double-click on the license file as this will always open the PlanetPress Connect Activations Tool. Instead, open PlanetPress Workflow manually and apply the license through the activations dialog within. Activating PlanetPress Connect To activate PlanetPress Connect, simply save the license file somewhere on your computer where you can easily find it, such as on your desktop.
-
Before installing the software Before upgrading to a new version, even on a new workstation, consult the product's release note to find out about new features, bug fixes, system requirements, known issues and much more. Simply go to the product page and look for the "Release notes" in the Downloads area.
-
l l l l If you are upgrading to the latest version of Connect, it is recommended to open each template in Designer, produce a proof making sure the output is correct. Then send the template with its data mapping configuration, Job Creation and Output Creation preset files to Workflow by clicking on File > Send to Workflow... If you still use PlanetPress 7 legacy documents, PTK files can be imported by clicking on the Workflow tool button at the top left corner of the Workflow tool interface.
-
l Configure the Workflow services account as in the previous installation. If accessing, reading and writing to network shares, it is recommended to use a domain user account and make it a member of the local Administrators group on the new workstation. Once the user account has been chosen: 1. Click on Tools in the Workflow Configuration menu bar. 2. Click Configure Services. 3. Select the user account.
-
l l l OL Connect Print Manager Configuration files (.OL-ipdsprinter): C:\Users\ [UserName]\Connect\workspace\configurations\PrinterConfig OL Printer Definition Files (.OL-printerdef): C:\Users\ [UserName]\Connect\workspace\configurations\PrinterDefinitionCo nfig OMR Marks Configuration Files (.hcf): C:\Users\[UserName]\Connect\workspace\configurations\HCFFiles Where [username] is replaced by the appropriate Windows user name. Tip Actually, the path may not begin with 'C:\Users', as this is language-dep
-
Image, Fax and Search Modules l l Reconfigure the Image and Fax outputs with the new host information. Import the Search Profile and rebuild the database in order to generate the database structure required by the Workflow. Capture 1. Download the latest version of the Anoto PenDirector. 2. Before installing the PenDirector, make sure the pen’s docking station isn’t plugged into the server. Then install the PenDirector. 3.
-
Configuring the Connect Engines Any changes made to the Server preferences require the OLConnect_Server service to be restarted to take effect. 1. Stop the OLConnect_Server service from Control Panel > Administrative Tools > Services > OLConnect_Server > Stop. 2. Configure the Merge and Weaver Engines scheduling preferences as in the previous installation l l l Open the Server Configuration from: C:\Program Files\Objectif Lune\OL Connect\Connect Server Configuration\ServerConfig.
-
Transferring software licenses Once all the above resources have been transferred over to the new server, it is recommended to thoroughly test the new system - in demo mode - with sample files under normal production load to identify points of improvement and make sure the output matches the user’s expectation. Output generated at this point will normally bear a watermark which can be removed by transferring licenses from the old server to the new one.
-
To apply the PlanetPress Capture License: 1. Open the Workflow Configuration. 2. Click on Help on the Menu Bar and click on PlanetPress Capture License manager to import your license. Uninstalling PlanetPress Connect from the previous workstation It is recommended to keep the previous install for a few days until everything is completed. However, once your transition is successful and complete, the OL Connect software must be uninstalled from the original server. See "Uninstalling" on page 123.
-
l l PlanetPress Workflow 2022.1 and PlanetPress® Suite Workflow 7 cannot run simultaneously, since only one version of the Messenger service can run at a time. In fact, no two versions of Workflow can be run simultaneously on the same machine, regardless of versions. It is possible to switch between different versions running by shutting down one version's services and then starting the other. However, this is not recommended.
-
Note The scheduling settings were changed significantly in version 2019.2. Please make sure to record your current scheduling settings for reference before proceeding with an upgrade. Users of Connect prior to 2019.1 Users of Connect 1.0 should see "Users of Connect 1.0" on the facing page first. Users of Connect 1.1 should see "Users of Connect 1.1" on the facing page first. Users of all other Connect versions prior to 2019.1 should note that Update Client 1.2.
-
connect/#KB/FAQ/General/Installation_Upgrade.htm). Users of Connect 1.1 In order for users of PlanetPress Connect 1.1 to upgrade to any later version through the Update Manager it is necessary to install a later version (1.1.8 or later) of the Objectif Lune Update Client. If you do not have such a version installed already, the next time you run your Update Client it will show that there is an update available of itself to Version 1.1.8 (or later).
-
Whilst the probability of such a worst case scenario is remote, it cannot hurt to take some simple precautions, just in case. Backing up a virtual machine Backing up a virtual machine installation is relatively straight forward. Simply take a snapshot of the virtual machine instance, prior to upgrading. This would save all the localized preferences and configurations. Backing up a real machine Note The scheduling settings in version 2019.
-
French system, for example, it would be 'C:\Utilisateurs'. Type %userprofile% in a Windows File Explorer and press Enter to open the actual current user's home directory. Backup your database If you want to be completely thorough and be able to exactly replicate your existing system, you should also backup your existing Connect database. If the default MySQL database is being used as the Connect back-end database, we would recommend the MySQLDump tool be used for this.
-
This document provides information on the migration process and the requirements and considerations for existing PlanetPress Suite users to upgrade to the latest generation of our products. What does PlanetPress Connect contain? PlanetPress Connect is comprised of the following modules: l PlanetPress Workflow 2022.1. This is the natural evolution of PlanetPress Suite Workflow 7 (Watch, Office or Production). PlanetPress Workflow 2022.
-
You can keep everything you have The first thing to know is that you can keep your current PlanetPress Suite Workflow 7 configuration and your PlanetPress Suite Design documents. When upgrading to PlanetPress Connect, they will remain functional. Please note that PlanetPress Suite Workflow 7 and PlanetPress Workflow 8 cannot run at the same time. See "Information about PlanetPress Workflow" on page 65 for information about these limitations.
-
l l Even if you don’t recreate your existing PlanetPress Suite documents, you can easily change your workflow to convert your output to PDF, then output them in PCL to any device supporting it. The full version of PlanetPress Connect can open your company to the digital world by enabling you to send HTML responsive emails as well as creating dynamic responses and interactive web pages.
-
3. Then, using the PlanetPress Workflow 2022.1 setup, install PlanetPress Workflow and/or PlanetPress Image on the appropriate computers. (See "Installation and Activation" on page 32 for more details.) Note If Workflow installation finds that .NET 4.0 is not already installed, it will install that version as part of the setup process. If LaserFiche or the ICR libraries are chosen as part of the Workflow installation, then .NET 3.5 must also be installed. This will need to be installed manually, as .NET 3.
-
5. If you installed PlanetPress Workflow 2022.1 on a different computer, please see "How to perform a Workflow migration" on page 80 for help importing all those settings, if you wish to import them. 6. To launch the Upgrade wizard, open the PlanetPress Workflow 8 configuration tool and, from the Tools menu, launch the Upgrade Wizard. IMPORTANT: Before you start this process, make sure you have a backup of your current installation/computer.
-
7.
-
8. Then select the product from which you wish to upgrade: 9.
-
10.
-
11. After that you will need to get the activation file for your product. To obtain your activation, download the PlanetPress Connect installer from the Web Activation Manager (http://www.objectiflune.com/webactivationmanager/), follow the instructions for the installation using the serial number provided to you. You can activate your license through the Web Activation Manager. 12.
-
PlanetPress Workflow tool to which you want to send the PlanetPress Design document. How to perform a Workflow migration What do you need to consider when upgrading from PlanetPress Suite 7 to PlanetPress Connect Workflow 2022.1 on a new computer? Installing and Activating Workflow 2022.1 on a new computer Points to consider: l l l l Before installing, be sure to read "Installation and Activation" on page 32.
-
from the PlanetPress Suite Designer Help > Printer Activation menu option. When the "Activate a printer" dialog is launched, right click within it and select the Export context menu option, then save the file on the new computer. Double clicking on the .pac file will then activate all of your printers on the new computer. l l Login to our Web Activation Manager (www.objectiflune.com/activations) using your customer number and password to get your Printer Activation Codes.
-
computer: "C:\ProgramData\Objectif Lune\PlanetPress Suite 7\PlanetPress Watch\Documents" 2. Copy all the PlanetPress Suite 7 Documents and Compiled forms (*.ptk and *.ptz) from the Documents folder on the PlanetPress Suite computer and paste them into the equivalent folder on the Connect Workflow Computer. The PlanetPress Suite 7 folder would be "C:\ProgramData\Objectif Lune\PlanetPress Suite 7\PlanetPress Watch\Documents". The PlanetPress Connect Workflow 8 folder will be "C:\ProgramData\Objectif Lune\Plan
-
Make sure that you copy only the custom plug-ins. Alternatively, you can download custom plug-ins from http://planetpress.objectiflune.com/en/suite/resources/support onto the new computer. Once you've copied your PlanetPress Suite Workflow configurations to Connect Workflow, you can confirm their availability through the Plug-in Bar Uncategorized category. There you will find all the Custom plug-ins that have been installed.
-
l l l l l Manually install all external executables that will be referenced by the Connect Workflow processes in the configuration file. If possible, retain the local path structure as used on the older installation. If the Windows "TCP/IP Print Server" service is running on the new computer, it is recommended that you disable the Server so that it does not interfere with the PlanetPress LPD/LPR services. If you are using images from a virtual drive, copy the entire contents of "C:\ProgramData\Objectif
-
How to perform a Capture migration This page provides information on how to conduct a proper migration of a Capture solution. For information about Capture see: http://capture.objectiflune.com/en/howitworks. These steps must be executed after a proper Workflow Migration has been completed. Instructions on how to do such can be found here: "How to perform a Workflow migration" on page 80. Failure to do so will result in unexpected problems.
-
"C:\ProgramData\Objectif Lune\PlanetPress Workflow 8\PlanetPress Watch\capture" and overwrite the existing database. Note Prior to PlanetPress Suite 7.6, all Capture patterns, documents and several other details were contained within the one single database. As of PlanetPress Suite 7.6 a separate database has been used for the patterns alone (PPCaptureDefault.mdb). 5. Copy the contents of this folder: "C:\ProgramData\Objectif Lune\PlanetPress Suite 7\PlanetPress Watch\DocumentManager" to this folder: "C:\
-
to the old computer will be lost unless the steps to migrate are reproduce again. Once a Pen has been docked and the data transfer done, its memory is wiped, thus rending the parallel mode very hard to produce. It is not impossible, but describing how it can be done is beyond the scope of this migration article. Steps to migrate: 1. Update existing installation to PlanetPress Suite version 7.6 if not already done. 2. Install PlanetPress Connect Workflow 2022.1 on new computer. 3.
-
2. Select Messenger in the tree list, right click and select Stop from the context menu. Note These steps must be done for both PlanetPress Suite Workflow 7 and PlanetPress Connect Workflow 8. 5. Copy the file PPCaptureDefault.mdb from this folder on the PlanetPress Suite 7.6 computer: "C:\ProgramData\Objectif Lune\PlanetPress Suite 7\PlanetPress Watch\capture" to this folder on the new PlanetPress Connect Workflow 2022.1 computer: "C:\ProgramData\Objectif Lune\PlanetPress Workflow 8\PlanetPress Watch\c
-
> Service Console). 2. Select Messenger in the tree list, right click and select Start from the context menu options. 9. Contact your local Objectif Lune activation team and transfer any Pen(s) licenses across. Server Configuration Settings This chapter describes configuring the PlanetPress Connect Server. The Connect Server settings are maintained by the Connect Server Configuration utility tool which is installed alongside PlanetPress Connect.
-
l Engines preferences l "Automatic Restart Settings" on page 102 l "Hardware for Digital Signing preferences" on page 906 l "Language preferences" on page 103 l "Logging preferences" on page 908 l "Parallel Processing preferences" on page 103 Connection preferences Background The Connection preferences are a way to control precisely how to connect to the PlanetPress Connect Server. This preference page was added in Connect 2018.2 to simplify management of HTTP communication with Connect.
-
l l Private key Password: Enter the Private key password. Confirm password: Re-enter the password, to confirm it was entered correctly. Note Enabling HTTPS for the primary REST Services connection requires different ports be used for the internal connections (IPC and REST) between Connect Server and its engines. l Internal communication on separate ports checkbox: Set the internal connection communication ports. These settings are purely for Connect inter-engine communication.
-
l Maximum asynchronous tasks: Set the maximum number of requests that can be executed simultaneously. Note This does not limit the number of requests that can be received, just how many are processed in parallel. Additional requests are buffered and are processed as capabilities allow. The default asynchronous task setting is twice the number of processing cores available to the computer. This can be expanded, if the limitation is deemed a bottleneck.
-
"Connect Servers preferences" on page 914 sub-section of the Designer Preferences dialog. - When disabled, a username and password is not required to make REST request, and tasks in PlanetPress Workflow do not require them in the Proxy tab. Nor would a username and password be required on any remote Connect Designer that links to this Server.
-
Engine configuration The Connect Server cooperates with different engines to handle specific tasks. A DataMapper engine extracts data from a data file. A Merge engine merges the template and the data to create Email and Web output, or to create an intermediary file for Printed output. The intermediary file is in turn used by a Weaver engine to prepare the Print output. (For more information see: "Connect: a peek under the hood" on page 126).
-
This topic explains all of these settings and the principles behind them, and it provides guidelines for letting the Server manage the workload in such a way as to achieve the highest possible output speeds. Factors to take into account are: l l l Your licence, which imposes a speed quota (see "Speed quota: Pages Per Minute" below). The processing power of your machine. How many cores it has determines how many engines can be launched (see "Launching multiple engines" on the facing page).
-
l l l Weaver engines always require a Licensed task to run. Merge engines only require a Licensed task when creating Email or Web output. Merge engines involved in a Print process don't need a Licensed task in order to run. DataMapper engines don't need Licensed tasks. In situations where Print and Email and/or Web output are created at the same time, only the Merge engines that create Email/Web output count towards the maximum number of Licensed tasks for that type of output.
-
cores, Windows Task Manager will show 4 cores and 8 logical processors on its performance tab. On a CPU like this, 5 or 6 engines can be configured to run in parallel. To configure the number of engines: 1. Open the Connect Server Configuration utility tool (see "Server Configuration Settings" on page 89). 2. Under Parallel Processing, go to the Content Creation tab and set the number of Merge engines for the various tasks. 3. Go to the Output Creation tab and set the Reserved Weaver (Output) engines.
-
The Connect MySQL database needs a fast storage system (SSD or other fast devices) to be able to keep up with two or more DataMapper engines. When the database is installed on a system with a slow hard drive, adding a DataMapper engine may not increase the overall performance. Weaver engine Adding extra Weaver (Output) engine(s) might be useful when large Print jobs are to be run simultaneously with smaller Print jobs.
-
Depending on the answers to these questions, you can allocate processing power to jobs in order to run them as fast as possible, and/or in the order of your preference. The first step in this process is to define the size of small, medium and large jobs. Job size Connect lets you define job sizes by setting the maximum number of pages a job can have and still be considered a small job, and what the minimum number of pages a job can have in order to be considered large.
-
handled at the same time by that kind of engine, because there are only so many engines (and speed units) available. Note When each individual record in a job is composed of a very large number of pages, the Memory per engine setting and the machine's hard drive speed are probably more important than the number of Merge engines, since one record cannot be split over multiple cores (see "Memory per engine" on page 98).
-
having engines reserved for HTML output can help performance. l l By reserving a number of parallel engines for Print jobs of a certain size (see "Number of parallel engines per Print job" on page 99). More parallel engines will make them run faster, but they will have to wait (longer) if the required number of engines isn't available when they come in. By specifying target speeds for simultaneous Print jobs of a certain size.
-
Batch processing. In a batch processing situation, jobs don't have to be handled simultaneously. All jobs - whether they are big and small - are processed one after another. Every job should be handled as quickly as possible. It is therefor recommended to assign the maximum number of engines and target speeds to all jobs. Do not reserve engines for certain jobs. Web requests. In online communication, response times are critical.
-
l l Daily restart period begin: Only available if Daily restart in period selected. Enter the daily start time for the time window in which automatic restarts will be scheduled to occur. Daily restart period end: Only available if Daily restart in period selected. The end of the daily time window in which the automatic restarts are scheduled to occur. Memory limit Enter the memory limit for individual Engines.
-
Parallel Processing properties (Designer Preferences) Preset selection (Designer Preferences) Only the Custom setting is applicable to the Designer Preferences, so this option is always selected and the field made read-only. Content Creation Tab (Designer Preferences) A Tab with data that relates solely to Content Creation. The options are: l l Total Merge engines configured read only display: This is a read only entry that shows the total number of Merge engines available.
-
l Additional engine every (records) entry: This controls how many Merge engines are used for a Content Creation task. It means that for every additional 'x' records in the task, an additional Merge engine will be used. For example, with the default 100 record threshold, tasks with 1-100 records will be assigned 1 Merge engine, tasks with 101-200 get assigned 2 merge engines, tasks with 201-300 get assigned 3 merge engines, and so on. Note These entries aren't applied instantaneously. There is often a lag.
-
l l l l l l l Default - Basic settings that are good for running most things. Single jobs have preference over multi-tasking, however. Batch Print - Best settings for processing jobs, one by one, in a sequential, first in first out (FIFO) order. On demand Print - Best settings for processing many small print jobs simultaneously. On demand - Use when serving web pages, sending emails, and printing many on demand jobs simultaneously. Connect Send - Settings optimized for use with Connect Send.
-
is a Merge engine available. How many Merge engines to use is based on the number of records in the input data. Select from the following options: l Optimize per task: This runs each task with as many Merge engines as needed (until engines are exhausted). Using this option means that Merge engines will not be reassigned when new tasks come in. This option is better suited for batch processing.
-
engine for less than 100 records will probably not make a big enough difference to throughput speed. Obviously, there are situations where these assumptions will not apply. Note Currently, it’s only the print and PDF content creation tasks that use multiple Merge engines. l Reserve engines for on demand tasks group checkbox: Reassigning engines is not instantaneous when a new task arrives.
-
l l Licensed speed limit (pages per minute): This read only entry shows the current license speed limitations, in pages per minute. The speed limitations are determined by your Connect license. This information is to help you choose what settings would make sense when assigning the “Target speed” values later in the Tab. Licensed tasks limit: This read only entry shows the current license task (or job) limitations. Note The terms "job" and "task" can be used interchangeably.
-
target speed for small jobs, this will automatically allow more for the large and medium jobs. l l Medium job (engines): Optionally enter the number of Weaver engines to reserve for Medium jobs. Total Weaver engines configured: This read only entry shows the number of Weaver engines still available. This is the Total engine count, minus the number of engines assigned to both Small and Medium jobs. To change this value, you must update the total amount of Weaver Engines in the Engines preferences page.
-
simultaneous jobs by a ration of the target speed. Some general rules of thumb to apply when distributing target speed: n Do you need to change speeds? In many cases there will likely be no need to change the target speed. n The target speed is not a guaranteed actual speed, but a speed limit that the engine is allowed to exceed in order to utilize the licensed speed. n When changing the target speed, don’t be overly precise, you are unlikely to get that exact value anyway.
-
l page-break-before:always or page-break-after:always combined with data-repeat l page-break-after:always combined with page-break-before:avoid on the next sibling TR (or similar combinations) These issues will be addressed in a later PlanetPress Connect release. DataMapper: Automatic Date/Time does not work with certain negative UTC time zone offsets The new "Automatic" date parsing option in the DataMapper cannot parse dates with negative UTC time zone offsets of non-zero minutes.
-
Changed Omit Master Page Back behaviour In versions of Connect prior to 2020.2, if a page had no content except for a linked DataMapper background, then Connect would consider it an "empty" page when determining whether or not to "Omit Master Page Back in case of an empty back page" (available as an option in the sheet configuration of a section). This has now been fixed in Connect 2020.2, and such pages are no longer considered empty. This could impact on the output from existing templates.
-
If you have an existing AFP input license we ask that you contact your local Customer Care team after the initial license update is complete and have them add the AFP input option back into your license. (See (https://www.objectiflune.com/WebActivationManager/CareInfo.aspx.) Page break changes in 2019.1 Improved page breaking in Connect 2019.1 might impact upon some existing templates.
-
set @a=null,@c=null,@b=concat("show tables where",ifnull(concat(" `Tables_in_",database(),"` like '",@c,"' and"),'')," (@a:=concat_ws (',',@a,`Tables_in_",database(),"`))"); Prepare `bd` from @b; EXECUTE `bd`; DEALLOCATE PREPARE `bd`; set @a:=concat('optimize table ',@a); PREPARE `sql` FROM @a; EXECUTE `sql`; DEALLOCATE PREPARE `sql`; set @a=null,@b=null,@c=null; If using Microsoft SQL Server run the following command in a query window: sp_updatestats Windows 10 Search service impacting Connect The Windows
-
Engine Preferences: Backward Compatibility Issues introduced in 2018.2 l Prior to version 2018.2 Connect allowed a mixture of internal and external engines. As of PlanetPress Connect 2018.2 this is no longer allowed. When upgrading to PlanetPress Connect 2018.2 from such installations, the pre-existing settings will not only no longer apply, but can cause scheduling preference conflicts for the Merge and Weaver engines.
-
Pie charts l Default colors: The default colors (used when no pie chart colors are specified) have changed. Line and Bar charts l Legend label: In previous versions, the name for a values series (needed for the legend) could only be taken from a field outside the detail table. The value of the selected field would be used. Setting a different label required expanding the chart script. After conversion, the name of the field is used instead of the value.
-
To fix this, add http://updates.ca.objectiflune.com to the list of trusted web sites on that machine, or lower the internet access rules. Limit of 100MB of image files within a single job The browser component (Mozilla Gecko) used in the WYSIWYG editor of the Designer was updated for Connect 2018.1. This allows use of new CSS properties, such as flexbox. However this update also introduced a limit of 100MBs for image files included within a single job.
-
appear at the end of the installer. The workaround for the moment is to use the default installation path. The problem will be addressed in a later release. Switching languages Changing the language using the Window > Preferences > Language Setting menu option does not currently change all of the strings in the application to the selected language. This is a known issue and will be fixed in a later release. In the meantime we offer the following workaround for anyone who needs to change the language: 1.
-
The minimum supported MySQL version is MySQL 5.6. PostScript print presets The print presets for PostScript were changed from Version 1.1 onwards meaning that some presets created in Version 1.0 or 1.0.1 may no longer work. Any PostScript print preset from Version 1.0 that contains the following will not work in Version 2022.1: *.all[0].* Any preset containing this code will need to be recreated in Version 2022.1.
-
terminate normally and the error will be logged. 2. The file must be referenced via a UNC path e.g., file://///w2k8r2envan/z%20images/Picture/Supported/JPG/AB004763.jpg l l UNC paths are required because the services will be unable to access mapped network drives (Windows security feature). The engine processing the job will look on the local file system for the direct file path leading to the “resource not found” issue mentioned above.
-
service, conversion service and live preview tab in the Designer will not work and exhibit the following issues: l Images will be shown as 0 size boxes (no red 'X' is displayed). l Live preview does not progress, and when re-activated reports "browsers is busy". To fix the issue you must check the "Bypass proxy settings for local addresses" option. Merge/Weaver engines when printing The print operation in the Designer will automatically detect whether the Merge\Weaver engines are available and display
-
Designer and Server for the job to terminate successfully. l l The Windows printer must be installed on both the Server and Designer machines. When printing via the Server from a remote Designer, the output file remains on the Server machine. This is remedied by selecting “Output Local” in the Output Creation configuration. VIPP Output Some templates set up with landscape orientation are being produced as portrait in VIPP. It can also sometimes be the case that text and images can be slightly displaced.
-
Important: Stop any active Anti-Virus software before uninstalling Connect. Some anti-virus systems are known to block the uninstallation of MySQL datafiles, as well as blocking the uninstallation of the MySQL database application itself. Therefore it is highly recommended that any anti-virus application be stopped prior to uninstalling PlanetPress Connect, as otherwise the Connect uninstallation might not work correctly.
-
Note If an error occurs during uninstallation or after/when re-installing Connect after uninstalling it, please see: Problems during a Connect installation or version upgrade in Connect's Knowledge Base (https://help.objectiflune.com/en/kbconnect/#KB/FAQ/General/Installation_Upgrade.htm).
-
General information Connect consists of visible and invisible parts. The invisible parts process the Connect job to provide the actual output. They are introduced to you in the topic: "Connect: a peek under the hood" below. For information about Connect logging, see "Log files" on page 131. For a list of all file types used in Connect, see: "Connect file types" on page 133.
-
The Workflow server The Workflow server (also referred to as the 'Watch service') executes processes independently, after a Workflow configuration has been uploaded and the services have been started. The Workflow server can run only one configuration at a time. There are a number of services related to Workflow.
-
tool. The Workflow Service Console lets you start and stop the different services, except the Connect server, and see their log files (see Workflow Service Console). Note that Workflow isn't limited to Connect functionality. It was originally developed as part of the PlanetPress Suite. Many of the plugins in the Workflow configuration tool are older than Connect. They were left in for compatibility reasons, even though they aren't all useful or usable within Connect.
-
The Connect Server Configuration tool lets you change the settings for the Connect server, the engines and the service that cleans up the database and the file store. These settings can also be made in the preferences of the Designer. The Connect database The Connect database is the database back-end used by Connect itself when processing jobs. It can be either the MySQL instance provided by the Connect installer, or a pre-existing (external) instance (see "Database Considerations" on page 19).
-
The engines DataMapper engines. A DataMapper engine extracts data from a data file. The number of DataMapper engines is configurable (Engines preferences). Merge engine/s. A merge engine merges data with a template using the scripts in the template, in order to create content items. The number of merge engines is configurable (see Engines preferences): it can be increased depending on the capacity of the machine that runs the solution (see "Performance considerations" on page 26). Weaver engines.
-
Printing and emailing from the Designer To print or send email from within the Designer, the PlanetPress Connect service has to be running. The service is started automatically when the Designer starts, but it may not be running if the Connect Server and the Designer are installed on different computers. The PlanetPress Connect service can be found on the Services tab in the Task Manager. For a proof print the Connect server is not used. Proof printing is always done locally, by the Designer.
-
Every time output is generated, the Designer and/or Connect Server and any engines involved in the operation produce their own log files. Each component writes its log files to a dedicated subfolder of the Log folder. Merge engines write to the logs/Mergeengine folder, Weaver engines to the logs/Weaverengine folder, DataMapper engines to the logs/Datamapperengine folder, Server to the logs/Server folder, and so forth. Note that actions of the Cleanup service are only logged in the Server's log file.
-
l l The Designer's logging preferences are set via the Designer; see: "Logging preferences" on page 908. The Connect Server's settings are maintained by the Connect Server Configuration utility tool; see "Server Configuration Settings" on page 89. The logging level that is set applies to the Server as well as the engines. The Designer's log messages are also displayed in the Messages pane (see "Preflight Results and Messages" on page 1125).
-
l l l l .OL-package: A transfer file used to package one or many of the above files (the data model being part of both the template and the data mapping configuration). Created by using the File > Package dialog. (See "Package dialog" on page 1047.) .OL-script: One or more Designer scripts. Scripts personalize the output of a template. They are either added via wizards (see "Personalizing content" on page 830) or selfwritten (see "Writing your own scripts" on page 918).
-
OL Connect projects An OL Connect project is an automated process, or combination of processes, in which the Connect Server and Database are used. (For an overview of the architecture of the OL Connect software, see "Connect: a peek under the hood" on page 126). Typically, an OL Connect project aims at automating (part of) a company's communication with its customers, suppliers, or other parties.
-
Tip Sample Project The OL Connect software comes with a number of Sample Projects that generate a Workflow configuration, and any Connect templates, data mapping configurations, and Print Presets required to make the project work. For more information, see "Sample Projects" on page 1060 in the online help or the Sample Projects overview video on the OL Learn website.
-
Tip The Designer can send templates, data mapping configurations and print presets to a Connect Server; see "Sending files to Connect Server or to another server" on page 483. Versioned Projects You can create versioned projects. A versioned project retains a record of the changes made to any file in the project. You can review changes, and also revert to a previous version of a project, if necessary. Note Versioned projects are created from the Project menu at the top of the Welcome (or Home) screen.
-
Use the Versioning History option in the Project menu to display the history of all changes. The Versioning History panel contains a complete record of who did what, on which date, and for which reason. You can elect to revert to a version from within the history if something turns out to be flawed in your current project. Both the Designer and the DataMapper use Git integration to maintain the history of a Project.
-
As you work on your project files, you can commit the files in the project at any time. When you commit the project, a snapshot of the project is saved as a version. Any additional information associated with a resource in the project is recorded alongside the file. Both the Designer and the DataMapper use Git integration to maintain the history of a Project. Creating Versioned Projects Versioned projects are created from the Project menu at the top of the Welcome (or Home) screen.
-
5. Specify the parameters for the new template, and then select Finish. Your new project is created and displays in the Designer. 6. Add your content as usual, then select Save to save the template to disk. 7. To record this version in the repository, select Commit. This records the saved template as a new version in the repository. Note that you need to save your changes before you can commit. 8. Enter information to describe the changes, then select OK.
-
To see the history of the project: 1. With the project open in Designer, select Project > Versioning history from the menu bar. 2. The history displays in the Versioning History tab. You can select a version from the list to display more information about the changes made in that version. To restore a previous version, select the version, then select the restore icon. The project is reset to the state it was in when that version was committed.
-
Sample Projects A Sample Project generates a small Connect solution that is ready to be tested and deployed. The solution contains a specific Workflow configuration, as well as the Connect templates, data mapping configurations, and any Job Presets and Output Presets that are used in that configuration. This chapter describes the Sample Projects and the projects that they install. It will help you install, comprehend and customize the projects.
-
o A single PDF for the entire job (in which the invoices are grouped per customer). o One PDF per customer. One PDF per invoice. (See: "Sample Project: Print Transactional Jobs" on page 165.) The Workflow process implements the typical Print plugins (see "Print processes with OL Connect tasks" on page 190). o l l l l Basic web page. This project serves a simple web page, personalized via URL parameters. (See: "Sample Project: Serving a Web Page" on page 178.) Submitting data with webforms.
-
Installing the project To start the Sample Project, select File > New > Sample Projects > Basic Email from the menu. (See also: "Basic Email - Sample Project" on page 1061.) Note In order to use the project, OL Connect Server and OL Connect Workflow must be installed on the local machine. The wizard lets you select the folder in which you want the solution to be installed. In the selected folder, the Sample Project will create two subfolders: Configurations and Workspace.
-
The process should send the email messages along with a delivery note and the Return and Refund Policy to the email address entered in the Sample Project. This is the sender's address. Running the project Having tested the project, you will be ready to send it to Workflow; see Saving and sending a Workflow Configuration in Workflow's Online Help. The project will run when you copy the Sample Data.xml file from the Configurations\Data folder to the Workspace\In folder.
-
Note Even though email clients do not read CSS files, CSS files can be used with the Email context in the Designer. See "Using CSS files with HTML email" on page 551. Two attachments are added to the email, in different ways. l l The Return and Refund Policy PDF is stored in the template (in the Images folder). Rightclick the Email section and select Attachments to see how this is attached to the email. The delivery note is a dynamic attachment, based on a data field.
-
The Workflow configuration The project's Workflow configuration, Sending Email, contains just one process. It is a simple OL Connect Email process (see "Email processes with OL Connect tasks" on page 188). To open the configuration, open Workflow, click the Workflow button, select Open and browse to the project's Configurations\Resources folder. Double-click on a task to see its properties. l l l l The Folder Capture task reads the project's Workspace path from a global variable.
-
Much of the information in the extracted records isn't used in the email, but was used to create the delivery notes. The email addresses are used in the template (in the To field), but ignored in the Workflow process because it sends emails in test mode (see "The Workflow configuration" on the previous page). Using a Workflow variable The path to the delivery note is constructed via JavaScript: automation.variables.em_basic_workspace + '\\Delivery Notes\\' + record.fields.OrderNumber + '.
-
Input data If your input data is in a file, but the file is of a different type or has a different structure, create a new data mapping configuration to match it. (See "Creating a new data mapping configuration" on page 223.) When it's finished, send the new data mapping configuration to Workflow (see "Sending files to Workflow" on page 482). Then open the Workflow configuration, double-click the Execute Data Mapping task to open it and select the new data mapping configuration.
-
You could add text, images and other elements to the email (see "Content elements" on page 664) and change the layout (see "Styling and formatting" on page 785). Keep in mind though that there are special design standards for HTML email (see "Designing an Email template" on page 549).
-
Installing the project From the menu, select File > New > Sample Projects > COTG Timesheets to start the wizard. The wizard lets you select the folder in which you want the solution to be installed. In the selected folder, the Sample Project will create two subfolders: Configurations and Workspace. The project's resource files are saved to the Configurations folder. The Workspace folder is used for debugging or running the solution.
-
how this can be resolved in your setup. Testing the project Once the Sample Project has finished the installation, the project is ready to be tested. 1. If the templates and data mapping configurations haven't been sent to Workflow yet, do that first (see "Sending files to Workflow" on page 482). This requires that the Workflow service is running (see Starting the Workflow service in Workflow's Online Help). 2.
-
Note If the COTG app is unable to submit the data, you may have to change your network setup or remove the built-in restrictions in Windows 10 that prevent applications from sending data to the same computer. See "Installing the project" on page 151. Project details The templates The form The COTG Timesheet Form template contains a Web context with one Web section: Section 1 (see "Web pages" on page 580 and "Forms" on page 751).
-
The report The COTG Timesheet Report template contains a Print context with one Print section: Section 1 (see "Print sections" on page 518) and one Master Page (see "Master Pages" on page 537). Personalization is mostly done via simple text scripts. Such scripts look for a text surrounded by @ (e.g. @city@) and replace that by the correct data. To add a text script you just drag-anddrop data onto the template. (See: "Variable Data" on page 846.
-
In order to create this data mapping configuration, the input data needed to be saved to a file first (see "Sample Project: COTG Timesheets" on page 150). The sample data file is located in the Configurations\Data folder, but you will also see it when you open the data mapping configuration itself. The Workflow configuration There are four processes in the COTG Timesheets Workflow configuration.
-
Load External File task replaces the job file with the form. At the end of the process the Server Input task returns the job file (the form) to the app. Capturing data and generating output When the user submits a form, the cotg_ts_capture_data process writes the job file - the request in the form of XML - to a Temp folder in the Workspace and sends a response code to the app. This way there is no need for the COTG user to wait while output is being generated. The response to the app can be sent right away.
-
4. Use the saved file to expand the data mapping configuration (see "Opening a data mapping configuration" on page 227). Send the data mapping configuration to Workflow. 5. Send the Workflow configuration to the server. Saving input as sample data Testing a process in Debug mode is only possible with a sample data file. The process is preconfigured to use the Sample Data.xml file located in the Configurations\Data folder. To create your own sample data file: 1.
-
same in both. You could also: l Add text, images and other elements (see "Content elements" on page 664) l Change the layout (see "Styling and formatting" on page 785) l Change the "Media" on page 540. If you have an image of the stationery the PDF will be printed upon, add it to the Media to make designing the template little easier.
-
For general information about processes in Workflow see About Processes and Subprocesses, in the Online Help of Workflow. Sample Project: Print Promotional Jobs The Print Promotional Jobs Sample Project creates a simple, yet complete OL Connect project that produces promotional print output. The project extracts data from an XML file and uses that data to personalize a promotional letter.
-
Next, you have to select the desired output type: PDF, PCL or PostScript Level 3. Each of the output types is available in two variants. The 'Stationery' variants will include the virtual stationery (stored in the OL Connect template) in the output. This is a setting in the Output Creation Preset (see "Print settings" on page 162). Testing and running the project Once the Sample Project has finished the installation, the project is ready to be tested. 1.
-
The Media contains the virtual stationery. Whether this is included in or omitted from the final output depends on a setting in the Output Creation Preset. Personalization is mostly done via simple text scripts. Such scripts look for a text surrounded by @ (e.g. @city@) and replace that by the correct data. To add a text script you just drag-anddrop data onto the template. (See: "Variable Data" on page 846.) A few scripts are a little bit more sophisticated.
-
open the data mapping configuration itself: select File > Open from the menu; browse to the Configurations\Resources folder and select the data mapping configuration: PR_PROM Data XML. Print settings The Print context and Print sections can have their own print settings, such as Duplex printing or binding style (see "Print settings in the Print context and sections" on page 515). But in this template, they don't have any. The way the letter is outputted is determined (mostly) by an Output Creation Preset.
-
The plugin is set to handle the output 'Through Workflow'. This means that the task will return the output file to the Workflow process. l The Send to Folder Output task. This task writes the output file to a subfoler in the Workspace\Out folder. It makes use of system variables (see Standard variables) to dynamically create a subfolder based on the current month and year (%M_%y). The name of the file consists of the original file name (%O), the current time (%h%n%s) and the file extension.
-
Note If the input data is JSON, you don't need a data mapping configuration: JSON data can be used in a template as is. See: "Adding JSON sample data" on page 844. However, if you want the data to be saved in the Connect database, let the XML/JSON Conversion plugin convert the JSON to XML and create an XML data mapping configuration to extract the data. Template There are countless ways to customize the template to meet your exact requirements.
-
Print output To save the output to another kind of file, you could use one of the other Output Creation Presets. To do that, adjust the process in Workflow: double-click the All In One task to open it, and select the Output Creation Preset of your choice on the Output Creation tab. To change the settings in an Output Creation Preset, open it in the Designer: 1. Select File > Output Creation Presets from the menu 2. Click the Import button and browse to the Configurations\Resources\Output presets folder to s
-
The wizard lets you select the folder in which you want the solution to be installed. In the selected folder, the Sample Project will create two subfolders: Configurations and Workspace. The project's resource files are saved to the Configurations folder. The Workspace folder is used for debugging or running the solution. It has an In folder that may be used to monitor incoming data and an Out folder to write output files to.
-
Configurations\Data folder to the Workspace\In folder. The same output should appear in the same folders as before. Project details The invoice template The invoice is designed in the PR_TRAN Invoice template. It contains one Print section (see "Print sections" on page 518) and one Master Page (see "Master Pages" on page 537). The Media (virtual stationery) is included in the output - it is printed on the page's background , according to a setting in the Output Creation Presets.
-
The Text Script Wizard has an Expand button that opens the Script Editor, where you can edit the code or add your own. (For an introduction, see "Writing your own scripts" on page 918). When you double-click on the Invoice Meta script, the Script Editor opens immediately. This script shows how to add data using the replace() method (see https://www.w3schools.com/jsref/jsref_replace.asp). Note that this is a native JavaScript function.
-
All other print settings are in the three Output Creation Presets. These are used by the Create Output tasks in the Workflow process. To see the exact settings, open an Output Creation Preset in the Designer: first select File > Output Creation Presets from the menu; then click the Import button and browse to the Configurations\Resources\Output presets folder to select the preset.
-
does not have one Create Output task, but three. Each of them uses its own Output Creation Preset (see "Print settings" on page 168). Note that the Branch tasks back up the job file and job information, so that the main branch continues with a job file that is unaffected by what happens to the job file inside the branch. The Folder Capture task reads the project's Workspace path from a global variable. The value of that variable is set by the Sample Project when it installs the project.
-
Note If the input data is JSON, you don't need a data mapping configuration: JSON data can be used in a template as is. See: "Adding JSON sample data" on page 844. However, if you want the data to be saved in the Connect database, let the XML/JSON Conversion plugin convert the JSON to XML and create an XML data mapping configuration to extract the data. Template There are countless ways to customize the template to meet your exact requirements.
-
Send the Workflow configuration to the server (see Saving and sending a Workflow Configuration in Workflow's Online Help). Print output To save the output to another type of file, or to send it to a printer, you must change the Output Creation Presets. Output Creation Presets are edited in the Designer. 1. Select File > Output Creation Presets from the menu. 2. Click the Import button and browse to the Configurations\Resources\Output presets folder to select the preset. 3.
-
Installing the project From the menu, select File > New > Sample Projects > Submitting Data with Web Forms to start the wizard. See also: "Submitting Data with Web Forms - Sample Project" on page 1067.) Note In order to use the project, OL Connect Server and OL Connect Workflow must be installed on the local machine. The wizard lets you select the folder in which you want the solution to be installed. In the selected folder, the Sample Project will create two subfolders: Configurations and Workspace.
-
Saving input as sample data Testing a process in Debug mode is only possible with a sample data file. The process is preconfigured to use the Sample Data.xml file located in the Configurations\Data folder. To create your own sample data file: 1. Locate the Workflow configuration in the Configurations\Workflow folder and open it in Connect Workflow. 2. Select the process. 3. Enable the Send to Folder step (step 2 in the process). 4.
-
The scripts in the Thank you folder only affect the thank_you Web page; on the form Web page, nothing matches their selectors. Tip Hover over the name of a script in the Scripts pane to highlight parts of the template that are affected by the script. l l l Most of the scripts in the Thank you folder directly insert data that were submitted via the Web form; see "Inserting variable data directly (drag-and-drop)" on page 847.
-
followed by another task, the Create Web Content task returns its output to the Workflow process, where it can be viewed (click View as HTML). The data mapping configuration To extract the submitted data from the job file (the request XML), the process uses the data mapping configuration: WEB_FORM Data. To open it, select File > Open from the menu and browse to the Configurations\Resources folder.
-
4. Use the saved file to add the new data to the data mapping configuration (see "Opening a data mapping configuration" on page 227). Send the data mapping configuration to Workflow. 5. Open the thank_you Web section and use the new data fields to personalize the page (see: "Personalizing content" on page 830). Then send the template to Workflow again. Tip The Designer can have one data mapping configuration and one template open at the same time.
-
Workflow configuration Serving the two web pages could also be achieved using separate processes, but in fact it is more efficient to have a single process, as activity needs to be monitored for each process. In real life the submitted data will probably not be stored in the Data Repository, but used differently. This means that the Push to Repository task will need to be replaced by the appropriate tasks, but that won't change the way the submitted data is retrieved.
-
Workspace. The project's resource files are saved to the Configurations folder. The Workspace folder is used for debugging or running the solution. It has an In folder that may be used to monitor incoming data and an Out folder to write output files to. The selected folder's path is saved to a global variable in the Workflow configuration (see "The Workflow configuration" on page 181). Testing and running the project Once the Sample Project has finished the installation, the project is ready to be tested.
-
The Send to Folder step will now write the input data - the job file - to a file in the Workspace\Debug folder. When you select the file as sample file (on the Debug ribbon), it can be used to debug the process. Note however that the process will not return the web page to a browser, as it wasn't started by a browser. Tip The saved file can be used to create a data mapping configuration. Project details The web template The web page is designed in the WEB_HELLO Web Page template.
-
Tip You don't have to write a script yourself if you just want to insert some data directly into the template. You could simply drag-and-drop the data on the template or use the Text Script Wizard (see: "Variable Data" on page 846). The Workflow configuration The project's Workflow configuration, Serving a Web Page.OL-workflow, contains just one process. It is a simple OL Connect Web process (see "Web processes with OL Connect tasks" on page 192). The NodeJS Server Input task's HTTP action is set to hello.
-
Customizing the project A project is a great starting point for building an OL Connect solution. This part explains how to make changes to the project. Do you intend to expand the project into a solution where Workflow runs on a different machine that also has a different regional setting? Then indicate the desired encoding in the Designer preferences (see "Sample Project deployment settings" on page 912) before installing the project.
-
In order to further personalize the web page, open your data mapping configuration (or JSON data, if the input data will be in that format; see "Adding JSON sample data" on page 844) and use the data fields to personalize the page. (See: "Personalizing content" on page 830.) Tip The Designer can have one data mapping configuration and one template open at the same time. Use the tabs at the top of the workspace to switch between the two.
-
Workflow processes in OL Connect projects About Workflow processes A Workflow configuration consists of one or more processes. Each of these processes waits until it is time to run or until it receives the necessary input, and then does its job. A process is made up of tasks (also referred to as plugins). In the Workflow configuration tool they are divided into groups. For example: l l l l l l Input tasks look for certain input data on a certain channel and start a process when they find it.
-
l l l l Print process. A process that results in print output implements either the typical OL Connect Print plugins, or the All in One plugin which combines the Print plugins; see "Print processes with OL Connect tasks" on page 190. Email process. An email process outputs one or more emails; see "Email processes with OL Connect tasks" on page 188. Web process. A web process serves one or more web pages. The output can vary from a plain and simple web page to an extensive web form.
-
Data extraction The Execute Data Mapping task is likely to appear in a lot of OL Connect Workflow processes. It generates a record set in the OL Connect database by executing a data mapping configuration on a data source. Output creation Merging the records with a template is the job of one of the following tasks. Email The Create Email Content task creates email content items and sends them to the recipient. See "Email processes with OL Connect tasks" on page 188.
-
PlanetPress Suite Documents The Create PDF/VT task creates PDF/VT files from a PlanetPress Suite Document (created with PlanetPress Design). This PDF/VT is compatible with the Create Print Content task directly, without the use of an OL Connect template (PDF/VT mode). OL Connect database The following tasks let you act directly upon the OL Connect database: l l The Set Properties task adds properties as tags to items/sets in the OL Connect database.
-
Capture OnTheGo Workflow processes A Capture OnTheGo solution requires no less than three basic processes in a Workflow configuration: l l l One process that generates a document (most often, a form), stores it and notifies the COTG app of the document's existence. Note that this process doesn't send the actual document.
-
Tip An easy way to create a Connect email project, including the Workflow configuration and the files that it needs, is to use a Sample Project. See "Sample Project: Basic Email" on page 143. The structure of an OL Connect email process In an OL Connect Email process only one plugin is essential: the Create Email Content plugin. The Create Email Content task creates a set of emails, using the Email context in a Connect template, and sends them to the email server.
-
l l A template with an Email context. (See "Creating a template" on page 477.) If the email should contain variable data, you might need to make a data mapping configuration (see "Creating a new data mapping configuration" on page 223). If the input is going to be JSON data, you could add them to the design using a JSON file (see "Adding JSON sample data" on page 844).
-
l l l l The Execute Data Mapping task, or the Retrieve Items task. The Execute Data Mapping task extracts data from the job data file and puts them in a record set. This task works according to the instructions in a data mapping configuration, made with the DataMapper (see "Data mapping configurations" on page 222). The Retrieve Items task can be used to retrieve records from the OL Connect database. The Create Print Content task. This task merges data with a template, resulting in Print Content Items.
-
l A template with a Print context. (See "Creating a template" on page 477.) In addition, the process may use: l l l A data mapping configuration, or a data model at the very least, if the documents should contain variable data. (See "Creating a new data mapping configuration" on page 223.) A Job Creation Preset. (See "Job Creation Presets Wizard" on page 1230.) A Job Creation Preset defines where the output goes and makes it possible to filter and sort records, group documents, and add metadata.
-
that the Connect Server and Workflow must be on the same workstation in order to create Web output. The structure of a web process In a web process two plugins are essential: l An Input task. l The Create Web Content plugin. If the Input task is a Server Input task, that task will return the output of the process - the web page - to the caller. The HTTP Action of the Server Input task determines how the process is triggered.
-
Of course, numerous other tasks could be added to the process. If you'd want to save the output of the Create Web Content task - the web page - to a file, for example, the task would have to be followed by a Send to Folder task. The Create Web Content task can be found on the OL Connect tab of the Plug-In Bar in Workflow. For a description of all mentioned OL Connect tasks, see "OL Connect tasks" on page 185.
-
Batching means gathering and then printing previously created print content items. Commingling refers to documents originating from different templates being combined into one print batch. This topic explains how to batch, commingle, and - not the least importantly - sort and separate items into print batches with Connect. The Workflow tasks mentioned here can all be found on the OL Connect tab of the Plug-In Bar in Workflow. For descriptions of the tasks, see "OL Connect tasks" on page 185.
-
l l l If you want the Create Job task to use a Job Creation Preset, you must retrieve content sets. A Job Creation Preset can filter, sort, and group print content items, add meta data and make finishing settings (see "Print Presets" on page 1536). From a performance perspective, working with content sets is better. Retrieving content sets is faster than retrieving content items and thus can improve performance.
-
Content Set that was just created. Use two consecutive Set Properties tasks to set properties on both levels. l Through a Post Pagination script in the template. (See "Post Pagination Scripts" on page 970 and "contentitem" on page 1505.) In order to retrieve (sets of) items by data values, you may have to adjust the data mapping configuration (see "Data mapping configurations" on page 222). Note that a property can only be used to retrieve entities on the level on which the property was explicitly set.
-
l l Values: Print content items and sets don't contain data fields, but they do have a link to the data record with which they were created, so selecting and sorting them by value is still a possibility. Properties are key/value pairs that can be set on entities in the Connect database. There are two ways to do that: l l Using the Set Properties task. Ideally, the Set Properties task directly follows the Create Print Content task in a Workflow process.
-
A Job Creation Preset can only take content sets as input. So, if you want to use a Job Creation Preset, the Retrieve Items task must retrieve content sets from the Connect database, not content items. This also means that if you want to use properties in conditions to retrieve the correct items, those properties must be set on the content set level. However, any properties that you want to be used for filtering, grouping or sorting must be set on the content items.
-
OL Connect automation with Node-RED Node-RED is a programming tool for wiring together hardware devices, APIs and online services. It was originally developed by IBM as an open source project and evolved into a general purpose IoT/IIoT (Internet of Things/Industrial Internet of Things) programming tool. It provides a browser-based editor that makes it easy to wire together flows using the wide range of nodes in the palette. Objectif Lune has added its own set of nodes to this palette: OL Connect nodes.
-
l l l l l l l l l capture folder This node monitors a folder for incoming files. The folder path can be set via a global variable. Typically these global variables are populated in a startup flow. data mapping, data get, set properties These three nodes access the OL Connect database in order to either store or retrieve data - extracted from data files - or to set properties on the data. paginated content, paginated job, paginated output, all in one, preview pdf These nodes are create print output.
-
Note The documentation of all individual nodes is embedded in Node-RED's editor. Hover over a node in the palette at the left, or select the node in a flow; then click the book icon. Connection settings for OL Connect Server In order to setup a OL Connect Server connection: 1. Add one of the OL Connect nodes (not a cotg node) to a flow. 2. Double-click the node to open its Properties window and click the Edit Server icon (a pencil). 3.
-
There are two ways to deploy OL Connect resources to the File Store: using the Designer or from within a flow in Node-RED's editor. l l For instructions on sending files to the File Store from the Designer, see "Sending files to Connect Server or to another server" on page 483. OL Connect's file upload node sends files to the File Store from within a flow. When used in a Startup flow the uploaded files will be available to all flows in the project. See: "OL Connect Startup flow" on page 209.
-
Node-RED: nodes and common techniques The nodes and common techniques described in this chapter will help you to start creating flows for an OL Connect application in Node-RED. The typical flows that an OL Connect application may have are described separately; see "Flows in an OL Connect application" on the previous page. For the user documentation of Node-RED, please refer to Node-RED's website: nodered.org.
-
l l l The debug node displays the content of the msg object, which is passed between nodes in a flow, in the debug message console. Add a debug node - one for each property of the msg object - after another node to verify that the properties are changed as expected. The split node turns a single msg.payload consisting of an array into a series of messages, each of which has a payload containing one of the array's elements. Note that the Split node only works on msg.payload and not on its child objects.
-
Parsing a JSON string When a JSON file is read, the result is a JSON string. In order to access its data, that string needs to be parsed to its JavaScript Object representation. Node-RED provides the JSON node to do this conversion. The parsed data is written to the payload property of the msg object, which is passed on to the next node. Keys in the JSON become properties of the payload. Example After reading the manifest.
-
l Via the function node, using JavaScript. The node has access to the msg object as well as to the different contexts: context (i.e. the node's local context), , flow and global. The Context sidebar in the editor of Node-RED displays the contents of the context data store and allows to view the stored variables. The view consists of three sections, one for each context: node, flow and global. Variables stored in the global context of Node-RED are visible to all nodes, in all flows, on all tabs.
-
1. Add a change node to the flow. 2. Create a rule to 'Move' msg.payload.resources to msg.payload. Iterating over items in an array If items in an array need to be passed on individually, the flow will need to iterate over the items. This kind of loop is handled by Node-RED's split node. The split node turns a single msg.payload, consisting of an array, into a series of messages, each of which has a payload containing one of the array's elements. Note that the split node only works on msg.
-
OL Connect Startup flow A Startup flow is used in Node-RED projects for OL Connect to initialize global variables and to deploy OL Connect resources for the project. A typical startup flow involves the following standard nodes: inject, read file, JSON, change, split, and debug (see "OL Connect automation with Node-RED" on page 200), and one OL Connect node: file upload (see "OL Connect nodes" on page 200). Triggering a startup flow The inject node can trigger a flow in Node-RED.
-
Tip OL Connect's capture folder node can read the name of the folder to be monitored for incoming files from a global variable. Deploying OL Connect resources OL Connect's file upload node uploads a single file to the File Store. This node requires the path to the resource. This should be the full path to the resource or a path relative to either the Node-RED installation or a path relative to the current Node-RED project.
-
Tip An easy way to create the files that the typical OL Connect email flow needs, is to use a Sample Project. See "Sample Project: Basic Email" on page 143. You would use all files except the Workflow configuration file. The structure of an OL Connect email flow In an OL Connect email flow only one plugin is essential: the email content plugin. The email content node creates a set of emails, using the Email context in a Connect template. If the template doesn't need any data, set msg.
-
l l A template with an Email context. (See "Creating a template" on page 477.) If the email should contain variable data, you may need to create a data mapping configuration (see "Creating a new data mapping configuration" on page 223). If the input is going to be JSON data, you could add them to the design using a JSON file (see "Adding JSON sample data" on page 844). Note that before templates and data mapping configurations can be used in a flow, they must be sent to the OL Connect server separately.
-
l l l The paginated content node. This node merges the data with a template, resulting in Print Content Items. Templates are made with the Designer (see "Templates" on page 477). The paginated job node. This node turns a set of Print Content Items into a print job. Any job settings are passed on via a Job Creation Preset which is made with the Designer (see "Job Creation Presets" on page 1538). The paginated output node. This node creates the actual output file(s) and stores them in the File Store.
-
to be stored somewhere where the print flow can access them, in order to retrieve the Print Content Items. You could for example use MongoDB. Retrieving the output The print output node outputs two things: the ID of the output location in the File Store and an array containing the output file(s). Connect the print output node with the OL Connect file download node to download a ZIP archive of the entire job based on the msg.managedFileId provided by the print output node.
-
l An Output Creation Preset. (See "Output Creation Presets Wizard" on page 1246.) An Output Creation Preset can split a print job into smaller print jobs, and set printing options such as binding, OMR markings and the like. All of these files are made with the Designer and need to be sent to the OL Connect server before using them in a flow; see "OL Connect resources in Node-RED" on page 202.
-
The preview pdf node accepts runtime parameters. These can be passed via the parameters property of the msg object which is passed between nodes. For example, a runtime parameter named brandId would be passed via msg.parameters.brandId. Creating and saving multiple PDF files A PDF preview is usually needed in online solutions, but the preview PDF node can also be used in situations where a PDF file can be produced without an Output Creation Preset.
-
An OL Connect web flow in Node-RED This topic explains which nodes and files are used in a typical OL Connect web flow in NodeRED. Tip An easy way to create the files that the typical OL Connect web flow needs, is to use a Sample Project. See "Sample Project: Serving a Web Page" on page 178. You would use all files except the Workflow configuration file. The structure of an OL Connect web flow In an OL Connect web flow only one plugin is essential: the html content plugin.
-
Which node or nodes fit best, depends on where the data come from. The html content node accepts runtime parameters. These can be passed via the parameters property of the msg object which is passed between nodes. For example, a runtime parameter named brandId would be passed via msg.parameters.brandId. Tip: Use a change node or function node to set a property. See also: "Node-RED: nodes and common techniques" on page 204.
-
A Capture OnTheGo Repository ID and password are required in order to configure the COTG node in these flows. Making a form available to COTG app users The flow that creates and publishes COTG forms will usually have the following nodes.
-
Serving the form As soon as a COTG app user taps a button to download a new form, the second flow springs into action to serve the requested COTG form. l l l l The http in node receives the request from the COTG app. A change node can be used to construct the path to the form file (see "Concatenating strings" on page 208) and store it in msg.filename. The file node reads the file from the location given in msg.filename. The form data is returned in msg.payload.
-
The DataMapper The DataMapper is the tool to create a data mapping configuration. Data mapping configurations are used to extract data and transpose that data into a format that can be shared amongst different layouts and outputs created with the OL Connect Designer and Workflow. The original data, located in a file or database outside of OL Connect, is called a data source.
-
3. Build the data mapping workflow. A data mapping workflow always starts with the Preprocessor step and ends with the Postprocessor step. You can add as many steps as you like and edit the Data Model of the extracted data as required. See "Data mapping workflow" on page 246 and "The Data Model" on page 291. What's next? Use the data mapping configuration in the Designer module to create templates for personalized customer communications. To learn more, see "The Designer" on page 475.
-
Creating a new data mapping configuration A new data mapping configuration can be made with or without a wizard. When you open a data file with a DataMapper wizard, the wizard automatically detects a number of settings. You can adjust these settings. Next, the wizard automatically extracts as many data fields (or metadata, in case of a PDF/VT or AFP file) as it can, in one extraction step. Without a wizard you have to make the settings yourself, and configure the extraction workflow manually.
-
l From the File menu 1. Click the File menu and select New. 2. Click the Data mapping Configuration drop-down and select Files and then the file type: l Comma Separated Values or Excel (CSV/XLSX/XLS), l Microsoft Access l PDF, PS, PCL or AFP l Text l XML l JSON 3. Click Next. 4. Click the Browse button and open the file you want to work with. 5. Click Finish.
-
process) the conversion to PDF may influence the processing speed, depending on the available processing power. l l l Some advanced PCL to PDF options are available by calling LincPDF (PlanetPress Connect's PCL to PDF converter) command line module; see "Advanced PCL to PDF options" on page 239. Extracting data from a PDF that comes from a Windows printer queue (a PDF converted to PostScript, converted back to PDF by an Input task in Workflow) might not work.
-
l From the Welcome screen 1. Open the PlanetPress Connect Welcome page by clicking the or select the Help menu and then Welcome. icon at the top right 2. Click New DataMapper Configuration. 3. From the Using a wizard pane, select the appropriate file type. l From the File menu 1. In the menu, click File > New. 2. Click the Data mapping Wizards drop-down and select the appropriate file type. The steps to take with the wizard depend on the file type.
-
2. Click New DataMapper Configuration. 3. From the Using a wizard pane, select Generate counters. l From the File menu 1. In the menu, click File > New. 2. Click the Data mapping Wizards drop-down and select Generate counters. You can set the following parameters: l l l l l l l Starting Value: The starting number for the counter. Defaults to 1. Increment Value: The value by which to increment the counter for each record.
-
To save a data mapping configuration: l l In the "Menus" on page 328, click on File > Save, or click on Save As to save a copy of a data mapping configuration under a different name. In the "Toolbar" on page 405, click the Save button. If the data mapping configuration has not been saved before, you have to browse to the location where the data mapping configuration should be saved and type a name, then click Save.
-
Using the wizard for CSV and Excel files The DataMapper wizard for CSV and Excel files helps you create a data mapping configuration for such files. The wizard automatically detects delimiters and extracts all data in one extraction step. The wizard interprets each line in the file as a record. If your data file contains transactional data, you will probably want more lines to go in one record and put the transactional data in detail tables. The wizard cannot create detail tables.
-
After selecting the file, take a look at the preview to ensure that the file is the right one and the encoding correctly reads the data. Click Next. For an Excel file you can make the following settings: l l l First row contains field names: Uses the first row of the Excel sheet as headers, which automatically names all extracted fields. Sheet: Select the sheet from which the data should be extracted.
-
Finally click Finish. All data fields are automatically extracted in one extraction step. Using the wizard for databases The DataMapper wizard for database files helps you create a data mapping configuration for a database file. The wizard extracts the data in one extraction step. The wizard cannot create detail tables. If the file contains transactional data, the data mapping configuration is best created without a wizard (see "Creating a new data mapping configuration" on page 223).
-
Note After creating the initial data mapping configuration you may use a custom SQL query via the Input Data Settings; see "Settings for a database" on page 250. Tip The Sort on option, combined with the Stop data mapping option of the "Action step" on page 288, allows to process only a group of items without having to examine all records. (See also: "Action step properties" on page 377.) MySQL, SQL Server or Oracle l Server: Enter the server address for the database.
-
l Encoding: Choose the correct encoding to read the file. l Sort on: Select a field on which to sort the data, in ascending (A-Z) or descending (Z-A) order. Note that sorting is always textual. Even if the selected column has numbers, it will be sorted as a text. ODBC Data Source l l ODBC Source: Use the drop-down to select an ODBC System Data Source.
-
l l l l l Database name: Enter the exact name of the database from where the data should be extracted. User name: Enter a user name that has access to the server and specified database. The user only requires Read access to the database. Password: Enter the password that matches the user name above. Advanced mode: Check to enable the Connection String field to manually enter the database connection string. Connection string: Type or copy in your connection string.
-
After selecting a JSON file, specify if and how the JSON file must be split into multiple records. This is done by selecting an object or array as parent element. Its direct child elements objects and arrays, not key-value pairs - can be seen as individual source records. If the root is selected, there will be only one source record. Whether source records are output as individual records depends on the trigger.
-
Tip How to extract information from the metadata in the extraction workflow itself is explained in: "Extracting metadata" on page 259. If the data file doesn't contain any metadata, each page is a new record - in other words, a boundary is set at the start of a new page -, which is exactly what happens when you open the file without a wizard. You can open a PDF/VT or AFP file with a wizard using the Welcome screen or the File menu. l From the Welcome screen 1.
-
Note NOP (No Operation) records in AFP files cannot be extracted. Click Finish to close the dialog and open the actual Data Mapping configuration. On the Settings pane, you will see that the boundary trigger is set to On metadata. The selected metadata fields are added to the Data Model. Note Extracting data from a PDF that comes from a Windows printer queue (a PDF converted to PostScript, converted back to PDF by an Input task in Workflow) might not work (see the Connect Knowledge Base.
-
element is called an 'item'. Note that in addition to being valid, the JSON should follow naming rules for XML elements. For example, "adress_line_1:" is a valid key name in JSON, but it cannot be converted to a valid element name in XML because the colon is reserved for namespaces. For XML naming rules and best naming practices, see: XML elements on W3Schools. The wizard cannot create detail tables.
-
Note The DataMapper only extracts elements for which at least one value is defined in the file. Attribute values are not taken into account. Attribute values (prefixed with an @ sign in the Data Viewer) are not extracted automatically. Click Finish to close the dialog and open the data mapping configuration. Advanced PCL to PDF options The Connect DataMapper uses LincPDF to convert PCL files to PDF files. By default, the only options it passes to LincPDF are the input and output file names.
-
have a PCL Input license. Calling LincPDFC via an external program To set advanced conversion parameters, the PCL input file has to pass through an additional Workflow process before entering the process in which the data mapping takes place. The extra Workflow process should call the LincPDF command line module LincPDFC via the External Program plugin with the desired advanced conversion parameters. To create such a Workflow process: 1. Add a local variable to your process and name it lincPDFOptions. 2.
-
Key Name Argument Value Type Description EdgeToEdgePrinting -z 0 or 1 Set the flag of “Allows edge-to-edge printing”(default: FALSE). Constant Alpha -n:num 0-1 Specify constant alpha value defined in PDF 1.4 (default: 0.5). 0 or 1 When enabled, Lincoln’s PCL interpreter will output vector graphics in a simpler mode (default: FALSE). 0 or 1 When set (1), LincPDF will convert CMYK as RGB colorspace before writing (default: FALSE).
-
the Workflow log. 7. Save the output of LincPDFC using the –o folder specifier in the parameter (% {workingDir}\Temp, in this case.) In another Workflow process, import the created PDF with the Folder Capture input plugin, specifying the output folder of the previous process (%{workingDir}\Temp in the example) as input folder, and %O.pdf as the file mask.
-
Once you have the PDF as job file, you may pass it to the Execute Data Mapping plugin for further processing. LincPDFC Options To view the available options that can be set in LincPDF, run the executable (LincPDFC.exe) in a command prompt window. It will display a help message with available options.
-
/*Open Windows Command Prompt Change directory cd C:\Program Files\Objectif Lune\OL Connect\LPDFConv\Bin C:\Program Files\Objectif Lune\OL Connect\LPDFConv\Bin\LincPDFC.exe LincPDF for Command-Line, Version 2.6.6.14 Copyright (c) 2001-2007 Lincoln & Co., a division of Biscom, Inc. Usage: LincPDF -iInput.PCL [-oOutput.
-
-dTitle:$s : PDF Title -dSubject:$s : PDF Subject -dAuthor:$s : PDF Author -dKeywords:$s : PDF Keywords -dVersion:num : PDF Version (multiply by 10) Page Setup: -pWidth:num : Page Width (required only if Page Type is Custom) -pHeight:num : Page Height (required only if Page Type is Custom) -pXOff:num : Page X Offset (see also Measurement) -pYOff:num : Page Y Offset (see also Measurement) -pMeasure:num : Page Measurement (0-inch, 1-mm, 2-point) -pOrient:num : Page Orientation (0-Portrait, 1-Landscape) -pTyp
-
-yCopyContents : Enable Copying Text and Graphics from Document -yUse128Bit : Use 128-bit Encryption -yAssembleDocument : Enable Assemble Document (128-bit encryption only) -yExtractText : Enable Text and Graphics Extraction (128-bit encryption only) -yLowResolutionPrint : Enable Lower-level Resolution Printing (128-bit encryption only) Tips ---------------------------------------------------. using quotation mark for complicated string, for example, -dKeywords:"key1, key2" .
-
after the Data Mapping workflow has completed ("Postprocessor step" on page 289). When you create a new data mapping configuration, these steps are added automatically, but they don't actually do anything until you configure them. In between the Preprocessor and Postprocessor step, the workflow can contain as many steps as needed to extract the required data.
-
Editing steps The properties of each step in the extraction workflow become visible in the Step properties pane when you select that step in the Steps pane. The name of each step is shown in the Steps pane. You can change it under Description in the Step properties pane. The other properties are different per step type; see "Steps" on page 279. Rearranging steps To rearrange steps, simply drag & drop them somewhere else on the colored line in the Steps pane.
-
If any errors are encountered in one or more records, an error message will be displayed. Errors encountered while performing the extraction workflow on the current record will also be visible on the Messages tab. Note How many records are displayed in the Data Viewer (200, by default) is specified in the Record limit on the Settings pane. Data source settings After opening a data file you have to make a number of settings to make sure that the source data is interpreted and grouped the way you want.
-
fields, even if the field delimiter is the semicolon. For an explanation of all the options, see: "CSV file Input Data settings" on page 347. Settings for an Excel File For an Excel file you have to specify which sheet to use. You can also set how many lines should be skipped, if the first row contains field names or not, and how the data should be sorted. See: "Excel file Input Data settings" on page 348. Excel has its own way to display dates.
-
width if you are still working with old line printer data; etc. It is important that pages be defined properly. This can be done either by using a set number of lines or using a string of text (for example, the character “P”), to detect on the page. Be aware that this is not a Boundary setting; it detects each new page, not each new record. For an explanation of all the options, see: "Text file Input Data settings" on page 350.
-
Record boundaries Boundaries are the division between records: they define where one record ends and the next record begins. Using boundaries, you can organize the data the way you want. You could use the exact same data source with different boundaries in order to extract different information. If, for instance, a PDF file contains multiple invoices, each invoice could be a record, or all invoices for one customer could go into a single record.
-
Data format settings defined for a data source apply to any new extraction made in the current data mapping configuration. These settings are made on the Settings pane; see "Settings pane" on page 347. Settings for a field that contains extracted data are made via the properties of the Extract step that the field belongs to (see "Setting the data type" on page 300). Any format settings specified per field are always used, regardless of the user preferences or data source settings.
-
You can also define custom runtime parameters. With those, you could, for example: l l Pass a JSON structure, containing boundary information as well as the name and location of fields to be extracted dynamically from a data stream. This way, a generic data mapping configuration could be used to process several kinds of different files. Define default values that are different from one data mapping instance to the next, even when using the same data mapping configuration.
-
Note Runtime parameters are always added to the file currently visible in the workspace. To add a parameter: 1. Click the Add button. The Add Parameter dialog opens. 2. Give the runtime parameter a name. The name is needed to access the parameter in a script and to set its source in the automation tool. 3. Optionally, set a debug value. Note that the debug value is never actually used outside of the DataMapper. Its only purpose is to make it easier to design and test the data mapping configuration.
-
step" on page 288). Note that the property's value will be reset at the beginning of each source record. l l The data object has a properties array that lets you access custom properties of the data as a whole, i.e. the scope of the property is set to Entire data. (See: "data" on page 426.) These are read-only. To access a runtime parameter inside of any JavaScript code within the data mapping configuration, use automation.parameters.runtimeparametername. (See: "Objects" on page 419.
-
Preprocessor step The Preprocessor step allows the application to perform actions on the data file itself before it is handed over to the Data Mapping workflow. In addition, properties can be defined in this step. These properties may be used throughout the extraction workflow. For more information, see "Preprocessor step" on page 279. Adding an extraction In an extraction workflow, Extract steps are the pieces that take care of the actual data extractions. To add an Extract step: 1.
-
field name stays the same. Drop data on empty fields or on the record itself to add new fields. Special conditions The Extract step may need to be combined with another type of step to get the desired result. l l l Data can be extracted conditionally with a Condition step or Multiple Conditions step; see "Condition step" on page 284 or "Multiple Conditions step" on page 287. Normally the same extraction workflow is automatically applied to all records in the source data.
-
1. Select the field in the Data Model that contains the extracted lines. 2. On the Step properties pane, under Field Definition, click the drop-down next to Split and select Split lines. Adding fields to an existing Extract step For optimization purposes, it is better to add fields to an existing Extract step than to have a succession of extraction steps. To add fields to an existing Extract step: 1. In the Data Viewer pane, select the data that needs to be extracted. (See "Selecting data" on page 261.) 2.
-
4. Select the Level of the metadata on which the information can be found. 5. Select the Property to extract. Alternatively you could create a JavaScript extraction (see "Using scripts in the DataMapper" on page 411 and "extractMeta()" on page 437). Note NOP (No Operation) records in AFP files cannot be extracted. Editing fields After extracting some data, you may want to: l Change the names of fields that are included in the extraction. l Change the order in which fields are extracted.
-
If any errors are encountered in one or more records, an error message will be displayed. Errors encountered while performing the extraction workflow on the current record will also be visible on the Messages tab. Note How many records are displayed in the Data Viewer (200, by default) is specified in the Record limit on the Settings pane. Selecting data In order to extract the data, it is necessary to first define the data to be extracted, by selecting it.
-
Note In a Text or PDF file, when you move the selection rectangle directly after extracting data, you can use it to select data for the next extraction. However, moving the selection rectangle that appears after clicking on a field in the Data Model actually changes which data is extracted into that field. CSV/XLS/XLSX file or database recordset Tabular data is displayed in the Data Viewer in a table where multiple fields appear for each line and row in the original data.
-
In this tree view you can select elements just like files in the Windows Explorer. Keep the Ctrl key pressed down while clicking on key-value pairs or brackets to select multiple elements, or keep the Shift key pressed down to select consecutive elements. You can select multiple key-value pairs, arrays and objects even if those are in different elements. To get a better overview you can collapse any JSON level.
-
fields that contain promotional data is the same in each record. These data are stored on the root level of the extracted record. Transactional data , on the other hand, are used in communications about transactions between a company and their customers or suppliers: invoices, statements, and purchase orders, for example. Naturally these data differ per customer. They are stored in detail tables in the extracted record. The number of detail lines in a detail table can vary from record to record.
-
Tip To break out of a loop and immediately jump to the next task following the current loop, use an Action task and set its action to Break out of repeat loop. Note that such loops work well when the data are structured uniformly, e.g. when all rows have the same number of columns, and when detail data always start at the same point in the line. Obviously, that is not always the case.
-
3. (Optional.) Add an empty detail table via the Data Model pane: right-click the Data Model and select Add a table. Give the detail table a name. 4. Select the Repeat step on the Steps pane. 5. Start extracting data (see "Adding an extraction" on page 257). When you drag & drop data on the name of a detail table in the Data Model pane, the data are added to that detail table.
-
From an XML file The transactional data appears in repeated elements. 1. Right-click one of the repeating elements and select Add Repeat. This adds a Repeat step to the data mapping configuration. By default, the Repeat type of this step is set to For Each, so that each of the repeated elements is iterated over. You can see this on the Step properties pane, as long as the Repeat step is selected on the Steps pane. In the Collection field, you will find the corresponding node path.
-
The Goto step isn't used in XML extraction workflows in most cases. The DataMapper moves through the file using Xpath, a path-like syntax to identify and navigate nodes in an XML document. 2. (Optional.) Add an empty detail table via the Data Model pane: right-click the Data Model and select Add a table. Give the detail table a name. 3. Select the Repeat step on the Steps pane. 4. Extract the data: inside a repeating element, select the data that you want to extract.
-
1. Select the parent element of the repeating elements. 2. Right-click and select Add Goto. The Goto step will move the cursor to the start of the first line item. Instead of using a Goto step you could define the path to the collection of elements directly in the JsonPath Collection field of the Repeat step. 2. Right-click the opening bracket of the first of the repeating elements and select Add Repeat. This adds a Repeat step to the data mapping configuration.
-
In the DataMapper the JsonPath can be absolute (start with $ which is the root) or relative to the current position (start with . which is the current element). A JsonPath can be relative or absolute. Note, however, that with a relative JsonPath going up to a parent element is not possible. Tip The full JsonPath to an element is displayed at the bottom left of the window when you select it. To copy the path, right-click it and select Copy.
-
2. Add a Repeat step where the loop must stop. 1. In the line under the last line item, look for a text that can be used as a condition to stop the loop, for example "Subtotals", Total" or "Amount". 2. Select that text, right-click on it and select Add Repeat. The Repeat step loops over all lines until the selected text is found. 3. Include/exclude lines. Lines between the start and end of the loop that don't contain a line item must be excluded from the extraction.
-
3. Select that data, right-click on it and select Add Conditional. Selecting data - especially something as small as a dot - can be difficult in a PDF file. To make sure that a Condition step checks for certain data: Set the Right operand to Value (in the Step properties pane). Make a selection in the Data Viewer and click the Use selected text button in the Right Operand section. You will now be able to see whether or not the proper text is extracted by the current selection.
-
4. (Optional.) Add an empty detail table to the Data Model: right-click the Data Model and select Add a table. Give the detail table a name. 5. Extract the data (see "Adding an extraction" on page 257). When you drag & drop data on the name of a detail table in the Data Model pane, the data are added to that detail table.
-
lines. To learn how to handle this, see "Extracting data of variable length" on the next page. 6. Extract the sum or totals. If the record contains sums or totals at the end of the line items list, the end of the Repeat step is a good place to add an Extract step for these data. After the loop step, the cursor position is at the end of line items. 1. Select the amount or amounts. 2. Click on the end of the Repeat step ( ) in the Steps panel. 3. Right-click on the selected data and select Add Extraction.
-
Extracting data of variable length In PDF and Text files, transactional data isn't structured uniformly, as in a CSV, database or XML file. Data can be located anywhere on a page. Therefore, data are extracted from a certain region on the page. However, the data can be spread over multiple lines and multiple pages: l l Line items may continue on the next page, separated from the line items on the first page by a page break, a number of empty lines and a letterhead.
-
Using a Condition step or Multiple Conditions step Using a Condition step ("Condition step" on page 284) or a Multiple Conditions step ("Multiple Conditions step" on page 287) one could determine how big the region is that contains the data that needs to be extracted. In each of the branches under the Condition or Multiple Conditions step, an Extract step could be added to extract the data from a particular region. The Extract steps could write their data to the same field.
-
Page 277
-
Using a script A script could also provide a solution when data needs to be extracted from a variable region. This requires using a Javascript-based field. 1. Add a field to an Extract step, preferably by extracting data from one of the possible regions; see "Extracting data" on page 256. To add a field without extracting data, see "Expression-based field" on page 297. 2. On the Step properties pane, under Field Definition, select the field and change its Mode to Javascript.
-
Note that this script replicates exactly what can be done in a Condition step. In cases like this, it is recommended to use a Condition step. Only use a script when no steps are sufficient to give the expected result, or when the extraction can be better optimized in a script. Steps In the DataMapper, steps are part of an extraction workflow (see "Data mapping workflow" on page 246). They contain a specific instruction for the DataMapper, for example to extract data, create a loop, or apply a condition.
-
also lets you define properties and runtime parameters that can be used throughout the data mapping workflow. For a complete overview of the settings for a Preprocessor step, see: "Preprocessor step properties" on page 365. Properties and runtime parameters A data mapping configuration's properties hold data that can be used throughout the data mapping workflow to compare against in conditions or to complement the existing data.
-
Extract step The Extract step is essential in each and every data mapping configuration. It extracts data from the data source, based on their location (a row and column in CSV or tabular data, an XPath in XML, a JsonPath in JSON, or a region of the page in PDF and Text) or on JavaScript code. The data is stored in the record set that is the result of the extraction workflow. Fields always belong to an Extract step, but they don't necessarily all contain extracted data.
-
see: "Extracting data" on page 256. l Alternatively, right-click the Steps pane and select Add a Step > Add Extraction. Make the required settings on the Step properties pane. If an Extract step is added within a Repeat step, the extracted data are added to a detail table by default; see "Extracting transactional data" on page 263 and "Detail tables" on page 336.
-
Tip To break out of a loop and immediately jump to the next task following the current loop, use an Action task and set its action to Break out of repeat loop. Adding a Repeat step To add a Repeat step: 1. On the Steps pane, select the step after which to insert the Condition step. 2. Make sure that the cursor is located where the extraction loop must start. By default the cursor is located at the top of the page or record, but previous steps in the extraction workflow may have moved it down.
-
cursor starts off at the top-left corner of each record in the source data. The Goto step can move the cursor to a certain location in the current record. The target location can be relative to the top of the record or to the current position. When the Goto step is used within a Repeat step, it moves the cursor in each loop of the Repeat step. In this case the new location has to be relative to the current position. The Goto step isn't used in XML extraction workflows in most cases.
-
Extract steps can be added to both the 'true' and the 'false' branch (see "Extracting data" on page 256 and "Extracting transactional data" on page 263). In the Data Viewer pane, icons on the left indicate the result of the evaluation in the Condition step for each line: when true and when false.
-
l l On the Steps pane, select the step after which to insert the Condition step; then, in the Data Viewer, select some data, right-click that data and choose Add Conditional. In the Step properties pane, you will see that the newly added Condition step checks if the selected position (the left operand) contains the selected value (the right operand). Both operands and the operator can be adjusted. Note that the left operand is by default trimmed, meaning that spaces are cut off.
-
Rules are by default combined with AND. To change the way rules are combined, right-click "AND" in the Rule Tree, on the Step properties pane, and select OR or XOR instead. (XOR means one or the other, but not both.) Renaming a rule To rename a rule, double-click its name in the Rule Tree and type a new name. Multiple Conditions step The Multiple Conditions step is useful to avoid the use of nested Condition steps: Condition steps inside other Condition steps.
-
Adding a Multiple Conditions step To add a Multiple Conditions step, right-click the Steps pane and select Add a Step > Add Multiple Conditions. To add a case, click the Add case button to the right of the Condition field in the Step properties pane. Configuring a Multiple Conditions step For information about how to configure the Multiple Conditions step, see "Multiple Conditions step properties" on page 396.
-
l l l Set the value for a record property. Record properties are defined in the Preprocessor step; see "Preprocessor step" on page 279. Stop the processing of the current record and move on to the next one. Normally an extraction workflow is automatically executed on all records in the source data. By stopping the processing of the current record, you can filter out some records or skip records partially.
-
l Select the Postprocessor step on the Steps pane. l On the Step properties pane, under Postprocessor, click the Add button l . Under Postprocessor definition, add the script. Postprocessor tasks must be written in JavaScript (see "Using scripts in the DataMapper" on page 411 and "DataMapper Scripts API" on page 408). Configuring the Postprocessor step For an explanation of the settings for post-processors, see "Postprocessor step properties" on page 403.
-
mapping workflow. In order to test post-processors you must execute them manually by clicking the Apply button in the Post-processor step properties (see "Postprocessor step properties" on page 403). Note that in the DataMapper and Designer, only one data record is active at any given time. Therefore, the changes made by the post-processes are only visible on the current data record (i.e. the one currently displayed).
-
About records A record is a block of information that may be merged with a template to generate a single document (invoice, email, web page...) for a single recipient. It is part of the record set that is generated by a data mapping configuration. In each record, data from the data source can be combined with data coming from other sources. Records can be duplicated by setting the number of copies in a script (see "record" on page 450). Duplicates are not shown in the Data Model.
-
Note l l Imported Data Model fields always overwrite existing field properties when the field name is the same (although they will still be part of the same Extract step). Nonexistent fields are created automatically with the appropriate field settings. The import is case-insensitive. All imported data model fields are marked as required in the Data Model (indicated with an asterisk (*) next to their names).
-
directly through the record object (see the "Designer Script API" on page 1341 and "DataMapper Scripts API" on page 408). To change the order in which data are extracted, see "Renaming and reordering fields in an extraction step" on page 299. Moving fields To move a field, a group of fields or a detail table, you can simply drag and drop it to some other place in the Data Model.
-
be populated with data from different sources and formats, without the need to modify the template (see "Importing/exporting a Data Model" on page 292). In Workflow, when a data mapping configuration is used to extract data from a data source (see "Data mapping configurations" on page 222), the extracted data is stored in a record set in the OL Connect database. Adding fields and data via Workflow The Data Model is not extensible outside of the DataMapper.
-
l Use the Update Data Records plugin. l Add an Output task and check the option Update records with Metadata. l Select Metadata as the data source in the Create Preview PDF plugin. Note Many of these actions can also be performed using REST calls. Please refer to PlanetPress Connect Workflow documentation for more information about the plugins involved. Fields Extracted data are stored in fields in the Data Model (see "The Data Model" on page 291).
-
Expression-based field Expression-based fields are filled with the result of a (JavaScript) expression: the script provides a value. Note that the last value attribution to a variable is the one used as the result of the expression. There is a number of ways to add an expression-based field. Via the Steps pane 1. Make sure there is no data selection in the Data Viewer. 2. Right-click on an Extract step on the Steps pane and select Add a Step > Add Extract Field.
-
Tip The default extraction method for fields in a CSV or XLS(X) file is data.extract (columnName, rowOffset). Changing the expression to use the data.extractByIndex(index, rowOffset) method will allow the data mapping configuration to extract data from files that have the same structure, but different column names. Property-based field A property-based field is filled with the value of a property (see "Properties and runtime parameters" on page 253).
-
l l Drag & drop data into it. The field will be converted into a location-based field and is then accessible via the Step properties pane. Fill the field with an Action step (see Extracting data with a script). Fields that are filled this way are not accessible via the Step properties pane. Adding fields dynamically Outside of the DataMapper the Data Model cannot be changed. It isn't possible to add fields to it when using the data mapping configuration in an automated process.
-
Note About field names: l l Fields cannot have the same name, unless they are located on a different level in the record (e.g. root level, detail table). It is recommended that you do not use spaces in field names. When a data field is dragged into a template, the data field name is used in the selector of the script that is created, but any spaces will be removed. Also, data fields may be used as Metadata in a Workflow process, and spaces are not permitted in Metadata field names.
-
The default format for dates, numbers and currencies can be set in the user preferences ("DataMapper preferences" on page 893), in the data source settings ("Data source settings" on page 249) and per data field (in the Extract step properties, see "Data Format" on page 375). Setting a default value You may want to set a default value for a field, in case no extraction can be made. Make sure to set the data type of the field via the step properties (see above).
-
Note The last value attribution to a variable is the one used as the result of the expression. Deleting a field The list of fields that are included in an extraction is one of the properties of an Extract step. To delete a field: 1. Select the field: click on the field in the Data Model, or select the Extract step that contains the field that you want to delete, and in the Step properties pane, under Field Definition, select the field from the Field List. 2.
-
1. On the Data Model pane, click one of the fields in the detail table. 2. On the Step Properties pane, under Extraction Definition, in the Data Table field, you can find the name of the detail table: record.detail by default. Change the detail part in that name into something else. Note A detail table’s name should always begin with ‘record.’. 3. Click somewhere else on the Step Properties pane to update the Data Model. You will see the new name appear.
-
To create more than one detail table, simply extract transactional data in different Repeat steps (see "Extracting transactional data" on page 263). The best way to do this is to add an empty detail table (right-click the Data Model, select Add a table and give the detail table a name) and drop the data on the name of that detail table.
-
Page 305
-
Nested detail tables Nested detail tables are used to extract transactional data that are relative to other data. They are created just like multiple detail tables, with two differences: l l For the tables to be actually nested, the Repeat step and its Extract step that extract the nested transactional data must be located within the Repeat step that extracts data to a detail table. In their name, the dot notation (record.services) must contain one extra level (record.services.charges).
-
a number of "details" such as movie rentals or long distance calls.
-
The services can be extracted to a detail table called record.services. The "charges" and "details" can be extracted to two nested detail tables.
-
The nested tables can be called record.services.charges and record.services.details.
-
Now one "charges" table and one "details" table are created for each row in the "services" table. Data types By default the data type of extracted data is a String, but each field in the Data Model can be set to contain another data type. To do this: 1. In the Data Model, select a field. 2. On the Step properties pane, under Field Definition choose a data type from the Type drop-down. Changing the type does not only set the data type inside the record.
-
l "HTMLString" on page 317 l "Integer" on page 317 l "Float" on page 316 l "Currency" on the facing page l "Date" on page 313 l "Object" on page 318 Note The Object data type is only available in the DataMapper module. It can be used for properties in the Preprocessor step, but not for fields in the Data Model. Boolean Booleans are a simple true/false data type often used in conditions and comparisons.
-
Boolean expressions Boolean values can be set using an expression of which the result is true or false. This is done using operators and comparisons. Example: record.fields["isCanadian"] = (extract("Country") == "CA"); For more information on JavaScript comparison and logical operators, please see w3schools.com or developer.mozilla.org. Currency The Currency data type is a signed, numeric, fixed-point 64-bit number with 4 decimals. Values range from -922 337 203 685 477.5808 to 922 337 203 685 477.5808.
-
Building Currency values Currency values can be the result of direct attribution or mathematical operations just like Integer values (see "Integer" on page 317). Date Dates are values that represent a specific point in time, precise up to the second. They can also be referred to as datetime values. While dates are displayed as UTC (Coordinated Universal Time) or using the system's regional settings (see "Default Format" on page 893), in reality they are stored unformatted.
-
4. For the letters and patterns that you can use in a date format, see "Defining a date/time format" below. Data format settings tell the DataMapper how to read and parse data from the data source. They don't determine how these data are formatted in the Data Model or in a template. In the Data Model, data are converted to the native data type. Dates, for example, are converted to a DateTime object. How they are displayed in the Data Model depends on the preferences (see "Default Format" on page 893)..
-
date/time separators (i.e. / - :) . If one of those characters happens to be one of the reserved characters listed above, it must be escaped using the \ symbol. Note The markers that can be used when extracting dates are different from those that are used to display dates in a template (see the Designer's "Date and time patterns" on page 1356). Examples of masks Value in raw data Mask to use June 25, 2013 MM dd, YYYY 06/25/13 mm/dd/yy 2013.06.25 yyyy.mm.
-
The use of the JavaScript Date() object is necessary when creating dates through a JavaScript expression. For more information, see w3schools - JavaScript Dates and w3schools - Date Object. Example The following script creates a date that is the current date + 30 days: function addDays(date, days) { var result = new Date(date); result.setDate(result.getDate() + days); return result; } addDays(new Date(), 30); Float Floats are signed, numeric, floating-point numbers whose value has 15-16 significant digits.
-
Building Float values Float values can be the result of direct attribution or mathematical operations just like Integer values (see "Integer" below). HTMLString HTMLStrings contain textual data that includes HTML markup. They are essentially the same as String values except in cases where the HTML markup can be interpreted. Example: Assume that a field has the value He said WOW!.
-
l l Direct attribution: Assign an integer value directly, such as 42, 99593463712, record.fields.Total; or data.extract("TotalOrdered");. Mathematical operations: Assign the result of any mathematical operation. For example: 22+51, 3*6, 10/5, record.fields["InvTotal"], or sourceRecord.property.SubTotal. For more information on mathematics in JavaScript , see w3Schools - Mathematical Operators. For more advanced mathematical functions, see w3schools - Math Object.
-
l Extraction: l In the Data Model, select a field. l On the Step properties pane, under Field Definition set the Type to String. The field value will be extracted and treated as a string. l JavaScript Expression: Set the desired value to any string between quotes. Example: record.fields["countryOfOrigin"] = "Canada"; Building String values String values can be made up of more than just a series of characters between quotes.
-
xsi:schemaLocation="http://www.objectiflune.com/connectschemas/Data ModelConfig http://www.objectiflune.com/connectschemas/DataModelConfig/1_0_0_ 3.xsd" xmlns:xsi="http://www.w3.
-
Example: transactional details, in a simple invoice format PAGE 322
Example: nested tables (one table into another) PAGE 323
Keyboard shortcuts This topic gives an overview of keyboard shortcuts that can be used in the DataMapper. Keyboard shortcuts available in the Designer for menu items, script editors and the data model pane can also be used in the DataMapper; see "Keyboard shortcuts" on page 1100. Although some of the keyboard shortcuts are the same, this isn't a complete list of Windows keyboard shortcuts. Please refer to Windows documentation for a complete list of Windows keyboard shortcuts.
-
Key combination Function displays the corresponding menu.) The menu can then be browsed using the Enter key, arrow up and arrow down buttons.
-
Key combination Function or Ctrl + Shift + F4 Ctrl + F5 Revert Ctrl + F7 Next view Ctrl + Shift + F7 Previous view Ctrl + F8 Next perspective Ctrl + Shift + F8 Previous perspective Ctrl + F10 Save as Ctrl + F12 Send to Workflow / Package files F4 Ignore step/Reactivate step F6 Add an Extract step F7 Add a Goto step F8 Add a Condition step F9 Add a Repeat step F10 Add an Extract field F11 Add an Action step F12 Add a Multiple Conditions step Alt + F12 Add a Case step (under a
-
Key combination Function Home Go to the first step in the workflow End Go to the last step in the workflow Alt + V Validate records Shift + F10 or Ctrl + Shift + F10 Open context menu Viewer pane The following key combinations activate a function in the Viewer. Key combination Function Alt + - Open system menu Ctrl + - Zoom out Tip You can also use the mouse's scroll wheel in combination with the Ctrl button to gradually zoom in or out.
-
Data Model pane Key combination Function PageUp Go to previous record PageDown Go to next record Alt + CR Property page Alt + PageDown Scroll down to the last field Alt + PageUp Scroll up to the first field Steps tab Key combination Function Ctrl + - Zoom out Ctrl + + Zoom in Edit Script and Expression windows The following key combinations have a special function in the Expression and in the Edit Script windows (expanded view).
-
Key combination Function Ctrl + J Line break Ctrl + L Go to line; a prompt opens to enter a line number. Ctrl + Shift + D Delete line Shift + Tab Shift selected lines left Tab Shift selected lines right Ctrl + / Comment out / uncomment a line in code Ctrl + Shift + / Comment out / uncomment a code block Menus The following menu items are shown in the DataMapper Module's menu: File Menu l l l l l New...
-
l l l l l l Save: Saves the current data mapping configuration or Template to its current location on disk. If the file is a data mapping configuration and has never been saved, the Save As dialog appears instead. Save As...: Saves the current data mapping configuration or Template to a new location on disk. In the case of Templates, it is saved to a location that can be different than the local repository. Save All: Saves all open files.
-
l Delete Step: Deletes the currently selected step. If the step is a Repeat or Condition, all steps under it are also deleted. l Cut: Click to remove the currently selected step, or steps, and place them in the clipboard. l Copy: Click to place a copy of the currently selected step, or steps, in the clipboard. l Paste: Click to place any step, or steps, from the clipboard before the currently selected step in the "Steps pane" on page 363.
-
l l l Add Extract Field: Adds the data selection to the selected Extract step, if an extract step is currently selected. If multiple lines, nodes or fields are selected, multiple extract fields are added simultaneously. Add Multiple Conditions: Adds a condition that splits into multiple case conditions. Add Action Step: Adds a step to run one or more specific actions such as running a JavaScript expression or setting the value of a Source Record Property.
-
Panes The DataMapper screen contains the following panes. l "Settings pane" on page 347. The Settings pane contains settings for the data source. l "Steps pane" on page 363. The entire extraction workflow is visible in the Steps pane. l "The Data Viewer" on page 344. The Data Viewer shows one record in the data source. l "Step properties pane" on page 365. The Step properties pane contains all settings for the step that is currently selected on the Steps pane. l "Data Model pane" below.
-
l : Export Data Model: Click to browse to a location to save the Data Model file. The available file types are: l l l A Data Model file (*.OL-datamodel). A JSON file (*.json): A JSON object or an array of JSON objects representing records. A 'typed' JSON file (*.json). Note Typed JSON follows the structure of a JSON Record Data List (see the REST API Cookbook). Data field types are determined by the schema object in the JSON.
-
Note Moving and grouping fields in the Data Model has no impact on the order in which data are extracted, or on the final records in the OL Connect database. They only help you organize the Data Model visually. To learn how to change the order in which data are extracted, see "Renaming and reordering fields in an extraction step" on page 299. l l l Add Field: Click to add a new field at the current level (record or detail table).
-
l l Default Value: Click to set the default value for a field. This value is used if no extraction is present, or if an extraction attached to this field returns no value. Move: Click to move the selected field within the current level or group in the Data Model. (See: "Ordering and grouping fields in the Data Model" on page 293.) l Top: Move the field to the first place. l Up: Move the field one step up. l Down: Move the field one step down. l Bottom: Move the field to the last place.
-
Record navigation Records can be navigated via the Data Model pane. The default record level navigates between records both in the Data Model pane and the Data Viewer, while each detail table has a similar navigation that influences that table and each detail table under it. l l l l l l l l Expand/Contract: Click to hide or show any fields or tables under the current table level or in the current group (see "Grouping fields" on page 294).
-
Detail tables can be included in a template via a Dynamic Table ; see "Dynamic Table" on page 866. Renaming a detail table Renaming detail tables is especially useful when there are more detail tables in one record, or when a detail table contains another detail table. For this detail table, ‘products’ would be a better name. 1. On the Data Model pane, click one of the fields in the detail table. 2.
-
To create more than one detail table, simply extract transactional data in different Repeat steps (see "Extracting transactional data" on page 263). The best way to do this is to add an empty detail table (right-click the Data Model, select Add a table and give the detail table a name) and drop the data on the name of that detail table.
-
Page 339
-
Nested detail tables Nested detail tables are used to extract transactional data that are relative to other data. They are created just like multiple detail tables, with two differences: l l For the tables to be actually nested, the Repeat step and its Extract step that extract the nested transactional data must be located within the Repeat step that extracts data to a detail table. In their name, the dot notation (record.services) must contain one extra level (record.services.charges).
-
a number of "details" such as movie rentals or long distance calls.
-
The services can be extracted to a detail table called record.services. The "charges" and "details" can be extracted to two nested detail tables.
-
The nested tables can be called record.services.charges and record.services.details.
-
Now one "charges" table and one "details" table are created for each row in the "services" table. The Data Viewer The Data Viewer is located in the middle on the upper half of the DataMapper screen. It displays the data source that is currently loaded in the DataMapper, specifically one record in that data. Where one record ends and the next starts is determined in the Data Source settings (see "Record boundaries" on page 252).
-
l l l Hide/Show datamap : Click to show or hide the icons to the left of the Data Viewer which displays how the steps affect the line. Hide/Show extracted data : Click to show or hide the extraction selections indicating that data is extracted. This simplifies making data selections in the same areas and is useful to display the original data. Lock/Unlock extracted data : Click to lock existing extraction selections so they cannot be moved or resized.
-
workflow. Messages pane The Messages pane is shared between the DataMapper and Designer modules and displays any warnings and errors from the data mapping configuration or template. At the top of the Message pane are control buttons: l Export Log: Click to open a Save As dialog where the log file (.log) can be saved on disk. l Clear Log Viewer: Click to remove all entries in the log viewer. l Filters: Displays the Log filter (see "Log filter" below).
-
Settings pane Settings for the data source and a list of Data Samples and JavaScript files used in the current data mapping configuration, can be found on the Settings tab at the left. The available options depend on the type of data sample that is loaded. The Input Data settings (especially Delimiters) and Boundaries are essential to obtain the data and eventually, the output that you need. For more explanation, see "Data source settings" on page 249.
-
l l Skip empty lines: Ignore any line that has no content. Note that spaces are considered content. l Sort on: Select a field on which to sort the data, in ascending (A-Z) or descending (Z-A) order. Note that sorting is always textual. Even if the selected column has numbers, it will be sorted as a text. Excel file Input Data settings There are no settings for field separation in an Excel file, only settings with regards to the file as a whole.
-
average character in the font. l l l l l l Line spacing: Determines the spacing between lines of text. The default value is 1, meaning the space between lines must be equal to at least the average character height. Paragraph spacing: Determines the spacing between paragraphs. The default value is 1.5, meaning the space between paragraphs must be equal to at least 1.5 times the average character height to start a new paragraph. Magic number: Determines the tolerance factor for all of the above values.
-
l l l l l Table: Displays the tables and stored procedures available in the database. The selected table is the one the data is extracted from. Clicking on any of the tables shows the first line of the data in that table. Custom SQLbutton : Click to open the SQL Query Designer (see"SQL Query Designer" on page 361) and type in a custom SQL query.
-
The maximum value for this option is 65,535 characters. The default value is 80 characters. l Page delimiter type: Defines the delimiter between each page of data. Multiples of such pages can be part of a record, as defined by the Boundaries. l On lines: Triggers a new page in the Data Sample after a number of lines. l l l Cut on number of lines: Triggers a new page after the given number of lines.
-
this element is encountered. Note that higher-level nodes above the selected element are shown, but those below the selected element are not displayed unless the Show all elements option is checked. l Use XPath: Enter an XPath to create a delimiter based on the node name of elements. For example:./*[starts-with(name(),'inv')]sets a delimiter after every element of which the name starts with 'inv'. Note thatstarts-with()is an XPath function. For an overview of XPath functions, see Mozilla: XPath Functions.
-
Note The information contained in all of the selected parent nodes will be copied for each instance of that node. For example, if a client node contains multiple invoice nodes, the information for the client node can be duplicated for each invoice. The DataMapper only extracts elements for which at least one value or attribute value is defined in the file.
-
limit, use the value 0 (zero). l l Line limit: Defines the limit of detail lines in any detail table. This is useful for files with a high number of detail lines, which in the DataMapper interface can slow down things. This does not affect output production; when generating output, this option is ignored. To disable the limit, use the value 0 (zero). Trigger: Defines the type of rule that controls when a boundary is set, creating a new record.
-
l On page: Defines a boundary on a static number of pages. l l Number of pages: Defines how many pages go in each record. On text: Defines a boundary on a specific text comparison. l l l l l Start coordinates (x,y): Defines the left and top coordinates of the data selection to compare with the text value. Stop coordinates (x,y): Defines the right and bottom coordinates.
-
l On delimiter:Defines a boundary on a static number of pages. l l Occurrences: The number of times that the delimiter is encountered before fixing the boundary. For example, if you know that your documents always have four pages delimited by the FF character, you can set the boundaries after every four delimiters. On text: Defines a boundary on a specific text comparison.
-
l l l Use selected text button: copies the text in the current selection as the one to compare to it. Match case: Makes the text comparison case sensitive. On script: Defines the boundaries using a custom JavaScript. For more information see "Setting boundaries using JavaScript" on page 414. XML file boundaries The delimiter for an XML file is a node. The Boundaries determine how many of those nodes go in one record.
-
Note Only arrays and objects can be seen as a record. It is not possible to split the JSON between key-value pairs. l l Record limit: Defines how many records are displayed in the Data Viewer. This does not affect output production; when generating output, this option is ignored. To disable the limit, use the value 0 (zero). The default value is 200. Trigger: Defines the type of rule that controls when a boundary is set, creating a new record.
-
Tip Data samples can be copied and pasted to and from the Settings pane using Windows File Explorer. l Add : Add a new Data Sample from an external data source. The new Data Sample will need to be of the same data type as the current one. For example, you can only add PDF files to a PDF data mapping configuration. Multiple files can be added simultaneously. l Delete l Move up l Move down l l l Replace source. : Remove the current Data Sample from the data mapping configuration.
-
l l Current Locale Settings: Shows dates and times as formatted by Windows using the current Locale of the system on which Connect runs. All values are shown as a date including a time. ISO 8601 (UTC): Uses the ISO 8601 (UTC) format to display dates and times. All values are shown as a date including a time, taking the time zone into account. Note that when no time was specified with a date in the original file, the default time (12.00 AM) is used and converted; this may influence the displayed date.
-
l Negative Sign Before: Any value in a numeric field that has a "-" sign is interpreted as a negative value. l Decimal Separator: Set the decimal separator for a numerical value. l Thousand Separator: Set the thousand separator for a numerical value. l Currency Sign: Set the currency sign for a currency value. l Date Format: Set the date format for a date value. l l l l l l Automatic: Select this option to parse dates automatically, without specifying a format.
-
l l l l Tables: Lists all tables and stored queries in the database. Custom Query: Displays the query that retrieves information from a database. You may use variables and properties in the query, to make the selection dynamic. See "Using variables and properties in an SQL query" below. Each database type has their own version of the SQL query language. To learn how to build your own query, please refer to your database's user manual.
-
Example = SELECT {automation.variables.FieldList} FROM {automation.jobInfo.JobInfo9} If the Workflow variable defined as FieldList contains the value "id,name" and Job Info 9 contains the value "MyTable", then this custom query, once parsed, yields the following SQL statement: SELECT id,name FROM MyTable which is then executed. Steps pane The Steps tab displays the data mapping workflow: the process that prepares and extracts data.
-
You can also click on the Preprocessor step to select all the steps in the workflow to show a complete map of all the extracted data. Window controls The following controls appear at the top of the Steps pane: l Zoom In (CTRL +) l Zoom Out (CTRL -) : Click to zoom in by increments of 10% : Click to zoom out by increments of 10% Contextual menu You can access the contextual menu using a right-click anywhere inside the Steps pane. l Add a Step: Adds a step to the process.
-
Step properties pane The Step Properties pane is used to adjust the properties of each Step in the process (see "Steps" on page 279). The pane is divided in a few subsections depending on the Step and the data type. It always contains a subsection to name and document the selected Step. Other subsections allow you to edit or delete fields that belong to the Step (see "Fields" on page 296) or change the expected data format (see "Data Format" on page 375), for example.
-
Name: The name of the step. This name will be displayed on top of the step's icon in the Steps pane. Comments: The text entered here will be displayed in the tooltip that appears when hovering over the step in the Steps pane. Fixed automation properties The Fixed automation properties subsection lists all the fixed runtime parameters available from PlanetPress Workflow. These properties are equivalent to data within the PlanetPress Workflow process in which the data mapping configuration is applied.
-
access this property inside of any JavaScript code within the data mapping configuration, use automation.properties.ProcessName. l TaskIndex: This property contains the index (position) of the task inside the process that is currently executing the data mapping configuration but it has no equivalent in PlanetPress Workflow. To access this property inside of any JavaScript code within the data mapping configuration, use automation.properties.ProcessName.
-
l l l Each Record: These properties are evaluated and set at the beginning of each source record. Once they have been set, these properties can be modified via an Action step (see "Action step" on page 288), but they are always reset at the beginning of each source record. Type: The data type of the property. For more information see "Data types" on page 310. Debug Value: The initial value of the property. This is a JavaScript expression. See "DataMapper Scripts API" on page 408.
-
The Export button exports the current data file in its current state. Preprocessing may cost a lot of time when the data file is very large. You could use the exported file instead of the original file to avoid preprocessing while developing the workflow configuration. Preprocessor definition l Expression: Enter the JavaScript code to be performed on the data file. See "DataMapper Scripts API" on page 408.
-
l Field List: The Field List displays each of the single fields that belong to the selected step in a drop-down. Fields can be re-ordered and re-named within the Order and rename fields dialog (see "Order and rename fields dialog" on page 376). Select one of the fields to make further settings for that field. Tip To change the name of a field quickly, right-click it in the Data Model and select Rename.
-
Note If the selection contains multiple lines, only the first line is selected. l Properties: The value of the property selected below will be the value of the selected field. l l l Property: This drop-down lists all the currently defined properties (including system properties). Custom properties can be defined in the Preprocessor step; see "Preprocessor step" on page 279. For an explanation of the objects to which the properties belong, see "DataMapper Scripts API" on page 408.
-
l Post Function: Enter a JavaScript expression to be run after the extraction. A Post function script operates directly on the extracted data, and its results replace the extracted data. For example, the Post function script replace("-", ""); would replace the first dash character that occurs inside the extracted string. l l l l Use JavaScript Editor: Click to display the "boundaries" on page 421 dialog. Trim: Select to trim empty characters at the beginning or the end of the field.
-
l l Type: The data type of the selected data; see "Data types" on page 310. If the selected data is split (see below), this setting is applied to the first extracted field. Make sure that the data format that the DataMapper expects matches the actual format of the data in the data source; see "Data Format" on page 375. Split: l l l Split lines: Separate a multi-line selection into individual fields . Join lines: Join the lines in the selection with the Concatenation string defined below.
-
l XPath: The path to the XML field that is extracted. l Use selection: Click to use the value of the current data selection for the extraction. Note If the selection contains multiple lines, only the first line is selected. l Post Function: Enter a JavaScript expression to be run after the extraction. For examplereplace("-","")would replace a single dash character inside the extracted string. l l Use JavaScript Editor: Click to display the "boundaries" on page 421 dialog.
-
Note If a key in a JSON file has a name that looks like a function (e.g. "TLIST(A1)"), then the Extract step has to use a JsonPath with bracket notation instead of the default dot notation. For information about the bracket notation see https://goessner.net/articles/JsonPath/. l Post Function: Enter a JavaScript expression to be run after the extraction. For examplereplace("-","")would replace a single dash character inside the extracted string.
-
l Date Format: Set the date format for a date value. l l l l l l Automatic: Select this option to parse dates automatically, without specifying a format. This is the default setting for new Date fields. ISO8601: This setting allows for dates with different timestamp formats, or belonging to different time zones, to be parsed inside a single job. Dates that do not include a specific time are automatically considered to use the current locale's time zone.
-
Note If you intend to use the field names as Metadata in a PlanetPress Workflow process, do not add spaces to field names, as they are not permitted in Metadata field names. l Value: Displays the value of the extract field in the current Record. l Remove button : Click to remove the currently selected field. l Move Up button : Click to move the selected field up one position. l Move Down button : Click to move the selected field down one position.
-
Actions This subsection lists all actions executed by the step, and their types. l Name: A name by which to refer to the action. This name has no impact on functionality. l Type: l l l l l Set property: Sets the value of a record property which was created in the Preprocessor step (see "Preprocessor step" on page 279). Run JavaScript : Runs a JavaScript expression, giving much more flexibility over the extraction process.
-
l Based on: Determines the origin of the data. l Location: The contents of the data selection set below will be the value of the extracted field. The data selection settings are different depending on the data sample type. l Left: Defines the start of the data selection to extract l Right: Defines the end of the data selection to extract l l l Top offset: The vertical offset from the current pointer location in the Data Sample (Viewer). Height: The height of the selection box.
-
Note If the selection contains multiple lines, only the first line is selected. l Data Format: Data format settings tell the DataMapper how certain types of data are formatted in the data source. Make sure that this format matches the actual format of the data in the data source. l Negative Sign Before: Any value in a numeric field that has a "-" sign is interpreted as a negative value. l Decimal Separator: Set the decimal separator for a numerical value.
-
l Based on: Determines the origin of the data. l Location: The contents of the data selection set below will be the value of the extracted field. The data selection settings are different depending on the data sample type. l l l Column: Drop-down listing all fields in the Data Sample, of which the value will be used. Top offset: The vertical offset from the current pointer location in the Data Sample (Viewer). Use selection: Click to use the value of the current data selection for the extraction.
-
l Data Format: Data format settings tell the DataMapper how certain types of data are formatted in the data source. Make sure that this format matches the actual format of the data in the data source. l Negative Sign Before: Any value in a numeric field that has a "-" sign is interpreted as a negative value. l Decimal Separator: Set the decimal separator for a numerical value. l Thousand Separator: Set the thousand separator for a numerical value.
-
For an overview of the JsonPath syntax, see https://github.com/jsonpath/jsonpath. l Use selection: Click to use the value of the current data selection for the extraction. Note If the selection contains multiple lines, only the first line is selected. l l Trim: Select to trim empty characters at the beginning or the end of the field JavaScript : The result of the JavaScript Expression written below the drop-down will be the value of the extracted field.
-
l Data Format: Data format settings tell the DataMapper how certain types of data are formatted in the data source. Make sure that this format matches the actual format of the data in the data source. l Negative Sign Before: Any value in a numeric field that has a "-" sign is interpreted as a negative value. l Decimal Separator: Set the decimal separator for a numerical value. l Thousand Separator: Set the thousand separator for a numerical value.
-
l Use selection: Click to use the value of the current data selection. Note If the selection contains multiple lines, only the first line is selected. Repeat step properties The Repeat step adds a loop to the extraction workflow; see "Steps" on page 279 and "Extracting transactional data" on page 263. The properties described below become visible in the Step properties pane when the Repeat step is selected in the Steps pane.
-
on selected nodes, you need to edit the Xpath/JsonPath in the Collection field (see below). If the path defines a rule that is true for more then one node/element, a collection of nodes/elements is returned and the For Each loop will go through all of them. Note When using a For Each loop in XML or JSON, it is not necessary to skip to the repeating node/element or to have a Goto step to jump to each sibling, as this loop takes care of it automatically.
-
Rule Tree The Rule tree subsection displays the full combination of rules (defined below under Condition) as a tree, which gives an overview of how the conditions work together as well as the result for each of these conditions for the current record or iteration. Condition First, the Condition List displays the conditions in list form, instead of the tree form above. Three buttons are available next to the list: l Add condition: Click to create a new condition in the list.
-
l l l l l l l l l l l Trim: Select to trim empty characters at the beginning or the end of the field. Value: The text value to use in the comparison. Use selected text: Uses the text in the current data selection as the Value. If multiple lines or elements are selected, only the first one is used. Field: The Extracted Record field to use in the comparison. JavaScript : The result of a JavaScript Expression.
-
l Operators: l l l l l l is equal to: The two specified value are identical for the condition to be True. contains: The first specified value contains the second one for the condition to be True. is less than: The first specified value is smaller, numerically, than the second value for the condition to be True. is greater than: The first specified value is larger, numerically, than the second value for the condition to be True. is empty: The first specified value is empty.
-
l l l l l Data Property: The value of a data-level property set in the Preprocessor step. Record Property: One of the local variables that you can create and that are reset for each document as opposed to data variables that are global because they are initialized only once at the beginning of each job. Automation Property: The current value of a Document-level property set in the Preprocessor step.
-
l Value: A specified static text value. l l l l l l l l Expression: The JavaScript line that is evaluated. Note that the last value attribution to a variable is the one used as a result of the expression. Use JavaScript Editor: Click to display the "boundaries" on page 421 dialog. Use selected text: Inserts the text in the current data selection in the JavaScript Expression. If multiple lines or elements are selected, only the first one is used.
-
l Invert condition: Inverts the result of the condition. For instance, is empty becomes is not empty. JSON files l Based On: l Position: The data in the specified position for the comparison. l l l l l l l l l Value: The text value to use in the comparison. Use selected text: Uses the text in the current data selection as the Value. If multiple lines or elements are selected, only the first one is used. Field: The Extracted Record field to use in the comparison.
-
l Extractor Property: The value of an internal extractor variable: l l l Counter: The value of the current counter iteration in a Repeat step. Vertical Position: The current vertical position on the page, either in Measure (PDF) or Line (Text and CSV). Operators: l l l l l l is equal to: The two specified values are identical for the condition to be True. contains: The first specified value contains the second one for the condition to be True.
-
Rule tree The Rule tree subsection displays the full combination of rules (defined below under Condition) as a tree, which gives an overview of how the conditions work together as well as the result for each of these conditions for the current record or iteration. l l To rename a rule, double click on its name from the Rule tree subsection. To change the way rules are combined, right-click "AND". Select OR or XOR instead. XOR means one or the other, but not both. (See XOR on Wikipedia.
-
l l l l l l l l l l l Value: The text value to use in the comparison. Use selected text: Uses the text in the current data selection as the Value. If multiple lines or elements are selected, only the first one is used. Field: The Extracted Record field to use in the comparison. Expression: The JavaScript line that is evaluated. Note that the last value attribution to a variable is the one used as a result of the expression.
-
l l l l l l is equal to: The two specified values are identical for the condition to be True. contains: The first specified value contains the second one for the condition to be True. is less than: The first specified value is smaller, numerically, than the second value for the condition to be True. is greater than: The first specified value is larger, numerically, than the second value for the condition to be True. is empty: The first specified value is empty.
-
Condition Left operand, Right operand The Left and right operand can be Based on: l Position: The data in the specified position for the comparison. l l Right (Txt and PDF only): The end position for the data selection. l Height (Txt and PDF only): The height of the selection box. l l l l l Top offset: The vertical offset from the current pointer location in the Data Sample (Viewer). XPath (XML only): The path to the XML field that is extracted.
-
l l l l l Use selected text: Inserts the text in the current data selection in the JavaScript Expression. If multiple lines or elements are selected, only the first one is used. Data Property: The value of a data-level property set in the Preprocessor step (see "Steps" on page 279). Record Property: One of the local variables that you can create and that are reset for each document as opposed to data variables that are global because they are initialized only once at the beginning of each job.
-
l l is empty: The first specified value is empty. With this operator, there is no second value. Invert condition: Inverts the result of the condition. For instance, is empty becomes is not empty. Goto step properties The Goto step moves the pointer within the source data to a position that is relative to the top of the record or to the current position. See also: "Steps" on page 279.
-
l l l From: Defines where the jump begins: l Current Position: The Goto begins at the current cursor position. l Top of record: The Goto begins at line 1 of the source record. Move by: Enter the number of lines or pages to jump. Next line with content: Jumps to the next line that has contents, either anywhere on the line or in specific columns. l Inspect entire page width: When checked, the Next line with content and Next occurrence of options will look anywhere on the line.
-
For more information on using Regular Expressions (regex), see the Regular-Expressions.info Tutorial. PDF file l Target Type: Defines the type of jump . l Physical distance: l l l l Current Position: The Goto begins at the current cursor position. l Top of record: The Goto begins at line 1 of the source record. Move by: Enter distance to jump. Page: Jumps between pages or to a specific page.
-
l Left: The starting column, inclusively. l Right: The end column, inclusively. l l l l Use selection: Click while a selection is made in the Data Viewer to automatically set the left and right values to the left and right edges of the selection. Expression: Enter the text or Regex expression to look for on the page. Use selection: Click while a selection is made in the Data Viewer to copy the contents of the first line of the selection into the Expression box.
-
child). The number of levels to change is defined in the Move by option. Use a negative value to jump to a parent element, a positive value to go to a child element. JSON file l Destination: Defines what type of jump to make: l l l l Sibling element: Jumps the number of siblings (elements at the same level) defined in the Move by option. Use a negative value to jump to the previous sibling, or a positive value to go to the next sibling.
-
Comments: The text entered here will be displayed in the tooltip that appears when hovering over the step in the Steps pane. Postprocessor The Postprocessor subsection defines what postprocessors run on the Data Sample at the end of the data mapping workflow. Each Postprocessor runs in turn, using the result of the previous one as an input. l Name: The name to identify the Postprocessor. l Type: The type of Postprocessor. Currently there is a single type available.
-
Postprocessor definition JavaScript l l l Expression: The JavaScript expression that will run on the Data Sample. See "DataMapper Scripts API" on page 408. Use JavaScript Editor: Click to display the Script Editor dialog. Use selected text: Uses the text in the current data selection as the Value. If multiple lines or elements are selected, only the first one is used. Toolbar In the DataMapper module, the following buttons are available in the top toolbar.
-
l l l l l l l l l l Add Condition Step: Adds a condition based on the current data selection. The "True" branch gets run when the text is found on the page. Other conditions are available in the step properties once it has been added. Add Repeat Step: Adds a loop that is based on the current data selection, and depending on the type of data. XML data will loop on the currently selected node, CSV loops for all rows in the record.
-
l l Add Data Sample: Displays a dialog to open a new Data Source to add it as a Data Sample in the data mapping configuration. Data Samples are visible in the "Settings pane" on page 347. Send to Workflow: Opens the "Send to Workflow dialog" on page 1082 to send files to a local Workflow software installation. Welcome Screen The Welcome Screen appears when first starting up PlanetPress Connect. It offers some useful shortcuts to resources and to recent documents and data mapping configurations.
-
l More options l l Get Printer Configurations (PDC): Lists printer definition files available for download. The selected files will be downloaded to the current user's Connect\workspace\configurations\ folder and can be imported via the Print Wizard; see "Adding print output Models to the Print Wizard" on page 1544. Get Finishing Configurations (HCF): Lists HCF Files available for download. High Capacity Feeders (HCF) are also commonly referred to as Inserters or FolderInserters.
-
Name Description Available in scripts of type "boundaries" on page 421 An object encapsulating properties and methods allowing to define the boundaries of each document in the job. Boundaries "data" on page 426 A data object encapsulating properties and methods pertaining to the original data stream. Boundaries, all steps except Goto "db" on page 443 An object that allows to connect to a database.
-
Name Description Available in scripts of type current data mapping configuration. Repeat and Multiple Conditions steps Functions These functions are available in Boundaries and Steps scripts. Name Description "Functions" on page 463 Copies a file to the target file path, replacing it if it already exists. "createGUID()" on page 464 Returns a unique 36-character string consisting of 32 alphanumeric, lower case characters and four hyphens (format: 8-4-4-4-12).
-
Name Description page 468 "newCharArray()" on page 468 Returns a character array. "newDoubleArray()" on page 469 Returns a double array. "newFloatArray()" on page 469 Returns a float array. "newIntArray()" on page 469 Returns an integer array. "newLongArray()" on page 469 Returns a long array. "newStringArray()" on page 470 Returns a string array. "openBinaryReader()" on page 470 Opens a file as a binary file for reading purposes.
-
A script can be used to set boundaries for a data source (see "Setting boundaries using JavaScript" on page 414). The script determines where a new record starts. Scripts can also be used in different steps in the extraction workflow. You can: l l l l Modify the incoming data prior to executing the rest of the extraction workflow, via a Preprocessor (see "Preprocessor step" on page 279).
-
Keyboard shortcuts for the script editor are listed in the following topic: "Keyboard shortcuts" on page 1100. Syntax rules In the DataMapper, all scripts must be written in JavaScript, following JavaScript syntax rules. For example, each statement should end with ; and the keywords that can be used, such as var to declare a variable, are JavaScript keywords. There are countless tutorials available on the Internet to familiarize yourself with the JavaScript syntax.
-
Setting boundaries using JavaScript As soon as you select the On Script option as the trigger for establishing record boundaries (see "Record boundaries" on page 252), you are instructing the DataMapper to read the source file sequentially and to trigger an event each and every time it hits a delimiter. (What a delimiter is, depends on the source data and the settings for that data; see "Input data settings (Delimiters)" on page 249).
-
l Compare the contents of one region with another. l Etc. To access this data in the script, use the get() function of the boundaries object. This function expects different parameters depending on the type of source file; see "get()" on page 423. Getting access to other data Data that is not passed with the event, but that is necessary to define the record boundaries, can be stored in the boundaries object using the setVariable function (see "boundaries" on page 421 and "setVariable()" on page 425).
-
Note The first line is just the header with the names of the CSV columns. The data is already sorted per year, per artist, and per album. Your goal is to examine two values in each CSV record and to act when either changes. The DataMapper GUI allows you to specify a On Change trigger, but you can only specify a single field. So for instance, if you were to set the record boundary when the "Released" field changes, you'd get the first four lines together inside a single record.
-
expects is simply the column name. The region is passed as a parameter to the get() method, which reads its contents and converts it into an array of strings (because any region, even a CSV field, may contain several lines). l l l To "remember" the values that were processed the last time the event was triggered, we use variables that remain available in between events. Note that these variables are specific to the Boundary context and not available in any other scripting context in the DataMapper.
-
The purpose of the script, again, is to set the record boundary when EITHER the year OR the artist changes. The script would look like this: /* Read the values of both columns we want to check */ var zeBand = boundaries.get(region.createRegion(1,1,30,1)); var zeYear = boundaries.get(region.createRegion(61,1,65,1)); /* Check that at least one of our variables holding previous values have been initialized already, before attempting to compare the values */ if (boundaries.
-
Note The PDF context also expects physical coordinates, just like the Text context does, but since PDF pages do not have a grid concept of lines and columns, the above parameters would instead be specified in millimeters relative to the upper left corner of each page. So for instance, to create a region for the Year, the code might look like this: region.createRegion(190,20,210,25) which would create a region located near the upper right corner of the page.
-
Property Description jobInfo Returns a ScriptableAutomation object containing Job Info 1 to 9 values from PlanetPress Workflow (see "Fixed automation properties" on page 366, and Job Info variables in the Workflow Online Help). properties Returns a ScriptableAutomation object containing additional information (ProcessName, OriginalFilename and TaskIndex) from PlanetPress Workflow (see "Fixed automation properties" on page 366).
-
boundaries Returns a boundaries object encapsulating properties and methods allowing to define the boundaries of each document in the job. This object is available when triggering document boundaries On script. Properties The following table lists the properties of the boundaries object. Property Description currentDelim A read-only 1-based index (number) of the current delimiter in the file. In other words, the Beginning Of File (BOF) delimiter equals 1.
-
Method Description Script type "Record boundaries" on page 252.) "setVariable()" on page 425 Sets a boundaries variable to the specified value, automatically creating the variable if it doesn't exist yet. Boundaries find() Method of the boundaries object that finds a string in a region of the data source file. The method returns the region in which the string was searched (PDF file) or the exact region in which the string was encountered (Text file). To check if the call to boundaries.
-
When used to search through a Text file, the find() method returns a different region object (see "region" on page 451) whose range property is adjusted to point to the exact physical location where the match was found. This will always be a subset of the in_Region.range property. It can be used to determine the exact location where the match occurred. Use boundaries.get() to retrieve the actual text from the resulting region; see "get()" below.
-
Note Boundary variables are carried over from one iteration of the Boundaries script to the next, while native JavaScript variables are not. getVariable(varName) varName String name of the variable from which the value is to be retrieved. If the variable does not exist, the value null is returned. It is considered good practice (almost mandatory, even) to always check whether a variable is defined before attempting to access its value. set() Sets a new DataMapper record boundary.
-
Example This script sets a boundary when the text TOTAL is found on the current page in a PDF file. The number of delimiters is set to 1, so the boundary is set on the next delimiter, which is the start of the next page. if (boundaries.find("TOTAL", region.createRegion (10,10,215,279)).found) { boundaries.
-
Note Boundary variables are carried over from one iteration of the Boundaries script to the next, while native JavaScript variables are not. setVariable(varName, varValue) Sets variable varName to value varValue. varName String name of the variable of which the value is to be set. varValue Object; value to which the variable has to be set. Example This script examines a specific region and stores its contents in a variable in the boundaries. var addressRegion = region.
-
Property Description step that have their Scope set to "Entire data". These properties are statically set at the start of the job. (See "Properties and runtime parameters" on page 253 for details.) Methods The following table lists the methods of the data object. Method Description Script type File type "extract()" on the facing page Extracts the text value from a rectangular region.
-
Method Description Script type File type "find()" on page 439 Finds the first occurrence of a string starting from the current position. Boundaries All Finds the first match for a regular expression pattern starting from the current position.
-
given position until the end of the record. Specifying an extraction height that is longer than the number of remaining lines results in a "step out of bound" error message. separator String inserted between all lines returned from the region. If you don't want anything to be inserted between the lines, specify an empty string (""). Tip l l "
" is a very handy string to use as a separator.
-
Example 2: The script command data.extract(1,22,9,6,"
"); means that the left position of the extracted information is located at 1, the right position at 22, the offset position is 9 (since the first line number is 10) and the regionHeight is 6 (6 lines are selected). Finally, the "
" string is used for concatenation.
-
extract(xPath) Extracts the text value of the specified node in an XML file. xPath String that can be relative to the current location or absolute from the start of the record. Example The script command data.extract('./CUSTOMER/FirstName'); means that the extraction is made on the FirstName node under Customer.
-
extract(columnName, rowOffset) Extracts the text value from the specified column and row in a CSV/XLS/XLSX file. The column is specified by name. To extract data from a column specified by index, use "extractByIndex(index, rowOffset)" on page 436. columnName String that represents the column name. rowOffset Number that represents the row index (zero-based), relative to the current position. To extract the current row, specify 0 as the rowOffset.
-
Example The script command data.extract('ID',0); means that the extraction is made on the ID column in the first row. extract(left, right, verticalOffset, lineHeight, separator) Extracts the text value from a rectangular region in a PDF file. All coordinates are expressed in millimeters. left Double that represents the distance from the left edge of the page to the left edge of the rectangular region.
-
Double that represents the distance from the left edge of the page to the right edge of the rectangular region. verticalOffset Double that represents the distance from the current vertical position. lineHeight Double that represents the total height of the region. separator String inserted between all lines returned from the region. If you don't want anything to be inserted between the lines, specify an empty string (""). Tip "
" is a very handy string to use as a separator.
-
extract(jPath) Extracts the text value of the specified element in a JSON file. jPath JsonPath expression (String) that can be relative to the current location or absolute from the start of the record. See also: "JsonPath" on page 263. Example The script command data.extract('$[0].FirstName'); means that the extraction is made on the FirstName element found in the first element in the array at the root.
-
Note that in order to access an extracted object or array in script, the extracted value has to be parsed, for example: var myData = JSON.parse(data.extract('$[0]')); extractByIndex(index, rowOffset) Extracts the value from the specified column and row. This function can be used to extract data from CSV or XLS(X) files that have an identical structure but don't have the same column names. index Number that represents a column in a CSV or XLS(X) file (1-based).
-
rowOffset Optional. Number that represents the row index (zero-based), relative to the current position. To extract the current row, specify 0 as the rowOffset. Use moveTo() to move the pointer in the source data file (see "moveTo()" on page 456). When omitted, the current row will be extracted. Examples The script command data.extractByIndex(1,0); means that the extraction is made on the first column in the first row, relative to the current position.
-
fieldExists(levelName, propertyName) This method returns true if the given metadata field exists at the given level in a PDF/VT or AFP file. levelName String, specifying a level in the PDF/VT or AFP file. propertyName String, specifying the metadata field. fieldExists(fieldName) This method returns true if a column with the specified name exists in the current record in a CSV, XLS or XLSX file. To verify whether a column specified by index exists in a CSV, XLS or XLSX file, use "Example" on the next page.
-
index Number that represents a column in a CSV or XLS(X) file (1-based). Example The following script accesses all columns in a CSV file: var allFields=[]; var i=1; while (data.fieldExistsByIndex(i)) { allFields.push(data.extractByIndex(i++)); } See also: "extractByIndex(index, rowOffset)" on page 436. find() Method of the data object that finds the first occurrence of a string starting from the current position.
-
Note Calling this method does not move the current position to the location where the string was found. This allows you to use the method as a look-ahead function without disrupting the rest of the data mapping workflow. stringToFind String to find. leftConstraint Number indicating the left limit from which the search is performed. This is expressed in characters for a text file, or in millimetres for a PDF file. rightConstraint Number indicating the right limit to which the search is performed.
-
findRegExp() Finds the first occurrence of a string that matches the given regular expression pattern, starting from the current position. findRegExp(regexpToFind, flags, leftConstraint, rightConstraint): rectValueText) Finds the first match for a given regular expression pattern starting from the current position. Regular expression flags (i,s,L,m,u,U,d) are specified in the flags parameter.
-
i: Enables case-insensitive matching. By default, case-insensitive matching assumes that only characters in the US-ASCII charset are being matched. Unicode-aware case-insensitive matching can be enabled by specifying the UNICODE_CASE flag (u) in conjunction with this flag. s: Enables dotall mode. In dotall mode, the expression . matches any character, including a line terminator. By default this expression does not match line terminators. L: Enables literal parsing of the pattern.
-
Examples data.findRegExp(/\d{3}-[A-Z]{3}/,"gi",50,100); or data.findRegExp("\\d{3}-[A-Z]{3}","gi",50,100);}} Both expressions would match the following strings: 001-ABC, 678-xYz. Note how in the second version, where the regular expression is specified as a string, some characters have to be escaped with an additional backslash, which is standard in JavaScript. db Object that allows to connect to a database. Methods The following table describes the methods of the db object.
-
java.lang.String-java.lang.String-java.lang.String-. In the returned Connection object normally any public method should be available. The returned Connection object is described here: https://docs.oracle.com/javase/8/docs/api/java/sql/Connection.html. Note Make sure to close any Connection object created by connect() and any other closable resources created from the Connection instance (ResultSet, etc.). url String that represents a database url of the form jdbc:subprotocol:subname, e.g.
-
else 'nothing'; values.close(); statement.close(); con.close(); logger Global object that allows logging messages such as error, warning or informational messages. Methods The following table describes the methods of the logger object. Method Parameters Description error() message: String Logs an error message info() message: String Logs an informational message warn() message: String Logs a warning message record The current record in the main data set.
-
Property Description tables The detail tables that belong to this record. You can access a specific table using a numeric index or the table name; see "table" on page 460. Example See this How-to for an example of how the current record index and/or the total number of records in the record set can be displayed in a document: How to get the record index and count.
-
The mandatory record parameter is a JavaScript object that contains one or more fields specified in the Data Model. The record parameter may contain a subset of the fields in the Data Model. Only the fields included in the record parameter are updated in the database, while the contents of all other fields remain unchanged.
-
var row = record.tables.myDescriptions[i].addRow(); record.tables.myDescriptions[row].set({customerName : "John Doe", customerAddress : "123 test road"}); setCopy(i, record) This method of the record object sets field values in a copy of the current record in the main data set. (See also: "record" on page 450.) Note This method cannot be used in post-processor scripts, because it operates on the current record before it is written to the database.
-
Note Dates must be passed as a Date object to allow them to be extracted into a Date field. See Date in the Mozilla help files. Passing an improper data type triggers an error. For instance the following objects are all invalid: { myBoolean : "true" } - The myBoolean field is boolean and expects a boolean, not a string { myDate : "2021-03-29" } - The myDate field is a date and expects a Date object: myDate: new Date(2021,2,29), not a string { myPageCount : 2.
-
record The current record in the main data set. Properties Property Description copies The total number of copies of the current record that must be created. By default, this is 1. This value is used when the record is saved, at the end of the data mapping process for each record. fields The field values that belong to this record. You can access a specific field value using either a numeric index or the field name. index The one-based index of this record, or zero if no data is available.
-
Method Description "setCopy(i, record)" on page 448 Sets field values in a copy of the current record. region The region object defines a sub-section of the input data. Its properties vary according to the type of data. This object is available when triggering document boundaries On script, with all file types; see "Setting boundaries using JavaScript" on page 414. Properties The following table describes the properties and methods of the region object.
-
Methods The following table describes the methods of the region object. Property/method Description Return Type "createRegion()" below Creates a region by setting the physical coordinates of the region object. A region that has the specified coordinates. createRegion() This method sets the physical coordinates of the region object. The region is available when setting document boundaries using a script (see "region" on the previous page).
-
if (regionStrings[i].match(/(\({2}n,*m*\){2}) /gi)){ boundaries.set(); } } } (The match() function expects a regular expression; see w3schools.) CSV or database: createRegion(columnName) Creates a region from the data in a CSV file, using the specified columnName parameter. columnName String containing the name of the column where the region is to be created. Example This script checks the first value in a certain column.
-
These are the custom properties defined in the Preprocessor step that have their Scope set to "Each record". See: "Properties and runtime parameters" on page 253. Properties sourceRecord.properties.property; Property Description properties Returns an array of properties defined in the Preprocessor step with the Record Scope (i.e. dynamically reset with each new record). steps Returns a steps object encapsulating properties and methods pertaining to the current DataMapper process.
-
Method Description File type which usually starts at 0. "currentPage" on the facing page Returns an integer value representing the current page where the current position is located, inside the current record. Text, PDF currentPageHeight The height of the current page in millimeters. PDF currentPageWidth The width of the current page in millimeters. PDF lines An integer value representing the number of lines in the current record of data.
-
(extraction) to the array */ } currentPage Property of the steps object (see "steps" on page 454) containing an integer value that represents the page where the pointer is located, inside the current record. In this example, an extraction area is assigned to the variable curLine each time the current page value has changed. curPage = steps.currentPage; for(i=0;i<100;i++) { if(steps.currentPage > curPage) { let curLine = data.extract(51, 88, 0, 1, "").
-
With the scope set to 2, verticalPosition is not used. The position is moved to the next line after the current position that contains any text. Example The following line of code moves the current position in a text file 14 lines down from the current vertical position (steps.currentPosition) of the pointer in the data, as long as it is on the same page. if(steps.currentPage > curPage) { steps.moveTo(0, steps.
-
String that defines a node in the XML file. Tip TheXML elementsdrop-down (on the Settings pane, under Input Data) lists xPaths defining nodes in the current XML file. moveTo(row) Moves the current position in a CSV file to the given row number. row Number that represents the index of the row, relative to the top of the record.
-
moveToNext(scope) Moves the current position in a text file or XML file to the next instance of scope. What scope represents depends on the emulation type: text or XML. Text scope Number that may be set to: l l l 0 or steps.MOVELINES: the current position is set to the next line. 1 or steps.MOVEDELIMITERS: the current position is set to the next delimiter (as defined in the Input Data settings). 2 (next line with content): the current position is set to the next line that contains any text.
-
l l 0 or steps.MOVENODE: the current position is set to the first available next element element in the JSON. The next element is looked for in the following order: first child, next sibling, parent's sibling. 1 or steps.MOVESIBLING: the current position is set to the next element in the same parent, i.e. the next element in an array or the next key-value pair in an object.
-
addRow(record) This method of the table object adds a record to an existing detail table (see "table" on the previous page). The detail table must already exist in the data model, otherwise the call fails. The call returns the index of the newly added record. record The optional record parameter is a JavaScript object that contains one or more fields specified in the Data Model for this detail table. The record parameter may contain a subset of the fields in the Data Model.
-
{ myPrice : "19.99" } - The myPrice field is a currency and expects a number value, not a string Example This script adds an empty row to a detail table called 'myDescriptions'. row = record.tables.myDescriptions.addRow(); set(record) The set() method of the table object sets field values in an existing detail table row. The row is specified by its index in the detail table: record.tables.
[index].set() If the index is invalid, the call fails.
-
Passing an improper data type triggers an error. For instance the following objects are all invalid: { myBoolean : "true" } - The myBoolean field is boolean and expects a boolean, not a string { myDate : "2021-03-29" } - The myDate field is a date and expects a Date object: myDate: new Date(2021,2,29), not a string { myPageCount : 2.5 } - The myPageCount field is an integer and expects a number without any decimals { myPrice : "19.
-
Example This script copies the file test.txt from c:\Content into the c:\out folder. copyFile("c:\Content\test.txt","c:\out\") createGUID() This function returns a unique 36-character string consisting of 32 alphanumeric, lower case characters and four hyphens. Format: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx (8-4-4-4-12 characters).| Example: 123e4567-e89b-12d3-a456-426655440000.
-
DataMapper script may have finished executing and gone out of scope. Supported properties l response l status l statusText l timeout (ms). Default: 1 minute. Supported methods create() l l open(String method, String url, String user, String password) open(String verb, String url, String userName, String password, String[] headers, String[] headervalues, String requestBody) l send() l send(String requestBody) Creates a new instance of ScriptableHTTPRequest. Opens a HTTP request.
-
setRequestHeader(String requestHeader, String value) Adds an additional HTTP request header. getResponseBody() Returns the full response body of the last HTTP request. setRequestBody(String requestBody) Sets the HTTP request body (for POST and PUT). getPassword() Gets the password for HTPP basic authentication setPassword(String password) Sets the password for HTPP basic authentication getTimeout() Gets the time to wait for the server's response setTimeout(int timeout) Sets the time (in ms.
-
In the following script, the contents of the data sample file are copied in uppercase to a temporary file. try{ // Open a reader var reader = openTextReader(data.filename); // Create a temporary file var tmpFile = createTmpFile(); // Open a writer on the temporary file var writer = openTextWriter(tmpFile.getPath()); try{ var line = null; // Current line /* read line by line and readLine will return null at the e the file */ while( (line = reader.readLine()) != null ){ // Edit the line line = line.
-
Examples 1. Deleting a file in a local folder: deleteFile("c:\Content\test.txt"); 2. Deleting the sample data file used in the DataMapper: deleteFile(data.filename); execute() Function that calls an external program and waits for it to end. execute(command) Calls an external program and waits for it to end. command String that specifies the path and file name of the program to execute. newByteArray() Function that returns a new byte array.
-
newDoubleArray() Function that returns a new double array. newDoubleArray(size) Returns a new Double array of the specified number of elements. size Integer that represents the number of elements in the new array. newFloatArray() Function that returns a new float array. newFloatArray(size) Returns a new Float array of the specified number of elements. size Integer that represents the number of elements in the new array. newIntArray() Function that returns a new array of Integers.
-
Integer that represents the number of elements in the new array. newStringArray() Function that returns a new string array. newStringArray(size) Returns a new String array of the specified number of elements. size Integer that represents the number of elements in the new array. openBinaryReader() Function that opens a file as a binary file for reading purposes. The function returns a DataInputStream (see DataInputStream).
-
end. openTextReader(filename,encoding) filename String that represents the name of the file to open. encoding String that specifies the encoding of the file to read (UTF-8, ISO-8859-1, etc.). Example In the following example, the openTextReader() function is used to open the actual data sample file in the DataMapper for reading. var var var var fileIn = openTextReader(data.filename); tmp = createTmpFile(); fileOut = openTextWriter(tmp.getPath()); line; while((line = fileIn.readLine())!=null){ fileOut.
-
Method Description close() Closes the stream and releases resources. open(inStream, inEncoding) Creates a reader from an input stream. Parameters: open(inFileName, inEncoding) parseCharset (inEncoding) l inStream: the input stream to read l inEncoding: the encoding to use when reading the file Creates a reader on the specified file. Parameters: l inFilename: the path of the file to read l inEncoding: the encoding to use when reading the file Returns a character set (Charset).
-
openTextWriter(filename, encoding, append) filename String that represents the name of the file to open. encoding String specifying the encoding to use (UTF-8, ISO-8859-1, etc.).. append Boolean parameter that specifies whether the file pointer should initially be positioned at the end of the existing file (append mode) or at the beginning of the file (overwrite mode).
-
Method Description close() Close the stream. newLine() Creates a new line in the file. open(filename) Creates a new writer on a file to write at the beginning of the file. Parameters: l open(inFilename, inEncoding, append) filename: the path of the file to open Creates a new writer on a file.
-
The Designer The Designer is a WYSIWYG (what you see is what you get) editor that lets you create templates for various output channels: Print, Email and Web. A template may contain designs for multiple output channels: a letter intended for print and an e-mail variant of the same message, for example. Content, like the body of the message or letter, can be shared across these contexts. Templates are personalized using scripts and variable data.
-
page 477. 2. Fill the template Add text, images and other elements to the template and style them. See "Content elements" on page 664 and "Styling and formatting" on page 785. 3. Personalize the content Personalize the content using variable data. See "Personalizing content" on page 830. 4. Generate output Adjust the settings, test the template and generate output: letters, emails, and/or web pages. See "Generating output" on page 1529.
-
l "Print" on page 504. This topic helps you design and fill sections in the Print context. l "Email" on page 547. This topics helps you design an email template. l "Web" on page 574. This topic helps you design a web page. "Sections" on page 500. Sections in one context are designed for the same output channel. "Content elements" on page 664. Elements make up the biggest part of the content of each design. "Snippets" on page 775.
-
There are Wizards for each output channel, or contexts as they are called in the Designer: Print, Email and Web. See: l "Creating an Email template with a Wizard" on page 552 l "Creating a Print template with a Wizard" on page 507 l "Creating a Web template with a Wizard" on page 575 Tip The quickest way to create a Print template based on a PDF file is to right-click the PDF file in the Windows Explorer and select Enhance with Connect.
-
Warning A template created in an older version of the software can be opened in a newer version. However, opening and saving it in a newer version of the software will convert the template to the newest file format. The converted template can't be opened in older versions of the software. Opening a package file Templates can also be stored in a package file (see "Creating package files" on page 482). To open a package file, switch the file type to Package files (*.OL-package) in the Open File dialog.
-
Saving older templates Saving a template in a newer version of the software will convert the template to the newest file format. This makes it unreadable to older versions of the software. The warning message that is displayed in this case can be disabled. To re-enable this message (and all other warning dialogs), go to Window > Preferences > General, and click the Reset All Warning Dialogs button at the bottom.
-
3. Type the number of revisions to keep. 4. Select the directory in which the backups should be stored. Backup files have the same name as the original template with two underscores and a progressive number (without leading zeros) at the end: originalname__1.OL-template, originalname__2.OL-template, etc. Note The Auto Save function does not cause backup files to be created. File properties On the menu, select File > Properties to view and complement the file properties.
-
Creating package files A package file (*.OL-package) contains one or more templates, data mapping configurations and Print Presets. A data mapping configuration file contains the information needed to extract data from a certain type of data file. For more information see "Data mapping configurations" on page 222.
-
more information see "Data mapping configurations" on page 222. Print Presets make it possible to do such things as filtering and sorting records, grouping documents and splitting the print jobs into smaller print jobs, as well as the more standard selection of printing options, such as binding, OMR markings and the like. See "Job Creation Presets Wizard" on page 1230 and "Output Creation Presets Wizard" on page 1246 for more details. To open the dialog, select File > Send to Workflow.
-
To create a custom template report, you need two files: A template design with the desired layout and variable data. This .OL-template file has to be made in the Designer. A data mapping configuration provides the variable data. You could use the data mapping configuration made for the standard template report, or create another one in the DataMapper module, using the standard XML template report as data sample.The DataMapper is included only in PlanetPress Connect and PReS Connect.
-
Import the Word Mail Merge document as a template 1. From within Connect Designer, select File > New and then select the Word-based Print template. 2. Navigate to the Word document, select it, then select Finish to import the file. Note that the mail merge fields are automatically converted to the proper format for Designer. Images from the word file are in the Images folder, and a script is created for each of the fields detected in the file. 3. Modify the template as needed.
-
media queries and a mobile-first approach, so that websites built upon Foundation look good and function well on multiple devices including desktop and laptop computers, tablets, and mobile phones. Foundation is tested across many browsers and devices, and works back as far as IE9 and Android 2. See http://foundation.zurb.com/learn/about.html. For more information about the use of Foundation in the Designer, see "Using Foundation" on page 617.
-
l l l l Set width to Grid: Check this option to limit the width of the top bar contents to the Foundation Grid, instead of using the full width of the page. Stick to the top of the browser window: Check to lock the top menu bar to the top of the page, even if the page has scroll bars. This means the menu bar will always be visible in the browser.
-
Web pages can be personalized just like any other type of template; see "Variable Data" on page 846 and "Personalizing content" on page 830. Tip Use the Outline pane at the left to see which elements are present in the template and to select an element. Use the Attributes pane at the right to see the current element's ID, class and some other properties. Use the Styles pane next to the Attributes pane to see which styles are applied to the currently selected element.
-
Contact Us The Contact Us template is a contact form that can be used on a website to receive user feedback or requests. It's great to use in conjunction with the Thank You template, which can recap the form information and thank the user for feedback. Thank You The Thank You template displays a thank you message with some text and media links. Blank web page The Blank Web Page template is a very simple Foundation template that contains a top bar menu and some basic contents to get you started.
-
After creating a COTG template, the other contexts can be added, as well as other sections (see "Adding a context" on page 499 and "Adding a Web page" on page 581). Tip If the COTG Form replaces a paper form, it can be tempting to stick to the original layout. Although that may increase the recognizability, it is better to give priority to the userfriendliness of the form. Keep in mind that the COTG form will be used on a device and don't miss the chance to make it as user-friendly as possible.
-
l l Kitchen Sink. The Kitchen Sink Template includes a wide range of basic form and COTG form elements demonstrating various possibilities of the software. Time Sheet. The Time Sheet Template is a single page application used to add time entries to a list. This template demonstrates the dynamic addition of lines within a COTG template, as the Add button creates a new time entry. There is no limit to the number of entries in a single page.
-
The Wizard opens the Web section, so that you can fill the Capture OnTheGo form. 6. Make sure to set the action and method of the form: select the form and then enter the action and method on the Attributes pane. The action of a Capture OnTheGo form should specify the Workflow HTTP Server Input task that receives and handles the submitted data. The action will look like this: http://127.0.0.
-
Capture OnTheGo templates can be personalized just like any other type of template; see "Variable Data" on page 846 and "Personalizing content" on page 830. Tip Use the Outline pane at the left to see which elements are present in the template and to select an element. Use the Attributes pane at the right to see the current element's ID, class and some other properties. Use the Styles pane next to the Attributes pane to see which styles are applied to the currently selected element.
-
pages, and snippets), JSON, JS and CSS. Internal resources Internal resources are files that are added to and saved with the template. To add images, fonts, style sheets, and snippets to your template, you can drag or copy/paste them into the Resources Pane. See also: "Images" on page 761, "Snippets" on page 775, "Styling templates with CSS files" on page 786 and "Fonts" on page 823. Resource files can also be dragged or copy/pasted out of the the application to save them on a local hard drive.
-
Note When referring to images or fonts from a CSS file, you need to remember that the current path is css/, meaning you can't just call images/image.jpg. Use a relative path, for example: #header { background-image: url('../images/image.jpg'); } External resources External resources are not stored in the template, but on the local hard drive or on a network drive. They are accessed using a path. The path must have forward slashes, for example PAGE 496
l l "Static Resources", as set in the preferences, are accessed using the resource path, by default something like http://servername:8080/_iRes/images/image.jpg. (For guidance on setting the preferences, search for 'HTTP Server Input 2' in the PlanetPress Workflow help files on: OL Help). Resources can also be served by processes: http://servername:8080/my_ process?filename=image.jpg (assuming "my_process" is the action in the HTTP Server Input).
-
1. Click the Add button ( ). 2. Give the parameter a name. 3. Select the data type. This impacts the way the data can be handled in a script; for example, if a parameter's type is Number, its value can be used directly in calculations, without having to parse it first. In the Parameters pane, the type of a runtime parameter can be recognized by its icon. 4. Optionally, set a default value. A default value will only be used in the case that there is no actual value coming from the automation tool, e.g.
-
l Click the Set Values button ( ) and edit the JSON. Note that this method cannot be used to change the name of a runtime parameter. You can only change the values and add new runtime parameters this way. If the Data Model contains a JSON Record Data List (see "A JSON Record Data List" on page 1034), you could edit the runtime parameters by adding or editing the parameters object using the "JSON sample data dialog" on page 1031.
-
with an Email Template Wizard; see "Creating an Email template with a Wizard" on page 552. Outputting and combining contexts All contexts can be present in any template and they can all be used to output documents; see "Generating Email output" on page 1560, "Generating Print output" on page 1531 and "Generating Web output" on page 1570. They can even be combined in output. If present in the same template, a Print context and a Web context can be attached to an Email context.
-
Warning If you don't have a backup of the template, the only way to recover a deleted section, is to click Undo on the Edit menu, until the deleted section is restored. After closing and reopening the template it is no longer possible to restore the deleted context this way. In the Saving Preferences you can set whether a backup file should be created when you save the template; see "Save preferences" on page 912. Sections Sections are parts of one of the contexts in a template: Print, Email or Web.
-
Editing a section To open a section, expand the Contexts folder on the Resources pane, expand the respective context (Print, Email or Web) and double-click a section to open it. Each section can contain text, images and many other elements (see "Content elements" on page 664), including variable data and other dynamic elements (see "Personalizing content" on page 830). To preview a section, open the Preview tab in the Workspace (see "Workspace" on page 1140). Copying a section To copy a section: 1.
-
Deleting a section To delete a section: l On the Resources pane, expand the Contexts folder, expand the folder of the respective context, right-click the name of the section, and then click Delete. Warning No backup files are maintained in the template. The only way to recover a deleted section, is to click Undo on the Edit menu, until the deleted section is restored, or by reverting to the last saved state (click File > Revert, on the menu).
-
1. Click and hold the mouse button on the style sheet on the Resources pane. 2. Move the mouse cursor within the Resources pane to the section to which the style sheet should be applied. 3. Release the mouse button. Using the Includes dialog 1. On the Resources pane, right-click the section, then click Includes. 2. From the File types dropdown, select Stylesheets. 3. Choose which CSS files should be applied to this section. The available files are listed at the left.
-
l On the Resources pane, expand the Contexts folder, expand the folder of the respective context, and then drag and drop sections to change the order they are in. Alternatively, right-click a section and click Arrange. In the Arrange Sections dialog you can change the order of the sections in the same context by clicking the name of a section and moving it using the Up and Down buttons. Outputting sections Which sections are added to the output, depends on the type of context they are in.
-
With the Designer you can create one or more Print templates and merge the template with a data set to generate personal letters, invoices, policies, or any other type of letter you can think of. The Print context is the folder in the Designer that can contain one or more Print sections. Print templates (also called Print sections), are part of the Print context. They are meant to be printed directly to a printer or a printer stream/spool file, or to a PDF file (see "Generating Print output" on page 1531).
-
Headers, footers, tear-offs and repeated elements (Master page) In Print sections, there are often elements that need to be repeated across pages, like headers, footers and logos. In addition, some elements should appear on each first page, or only on pages in between the first and the last page, or only on the last page. Examples are a different header on the first page, and a tear-off slip that should show up on the last page. This is what Master Pages are used for.
-
For more information about this feature see "Copy Fit" on page 802. Creating a Print template with a Wizard A Print template may consist of various parts, such as a covering letter and a policy. Start with one of the Template Wizards for the first part; other parts (called 'sections') can be added later. Print template wizards can be found in the Welcome screen and on the File menu.
-
Use the Styles pane next to the Attributes pane to see which styles are applied to the currently selected element. Basic Print template wizards There are two 'basic' Print Template wizards: one for a formal letter, and one for a postcard. Postcard The Postcard Wizard lets you choose a page size and two background images, one for the front and one for the back of the postcard.
-
Formal letter The Formal Letter Wizard first lets you select the page settings, see "Page settings: size, margins and bleed" on page 529. These settings are fairly self-explanatory, except perhaps these: l l l l Duplex means double-sided printing. The margins define where your text flow will go. The actual printable space on a page depends on your printer. The bleed is the printable space around a page. It can be used on some printers to ensure that no unprinted edges occur in the final trimmed document.
-
The Wizard opens the Print section. You can add text and other elements; see "Content elements" on page 664. The formal letter template already has an address on it. The address lines are paragraphs, located in one cell in a table with the ID address-block-table. As the table has no borders, it is initially invisible. The address lines will stick to the bottom of that cell, even when the address has fewer lines. See "Styling and formatting" on page 785 to learn how to style elements.
-
l l l A Print context with one section in it; see "Print context" on page 513 and "Print sections" on page 518. The selected PDF is used as the background of the Print section; see "Using a PDF file or other image as background" on page 523. For each page in the PDF one page is created in the Print section. One empty Master Page. Master Pages are used for headers, footers, images and other elements that have to appear on more than one page, and for special elements like tearoffs.
-
l A user script is created for each data field. l The mail merge fields are added to the Data Model of the OL Connect template. See "Creating a Word-Based Print template with mail merge" on page 484 for details. ERP templates The ERP template wizard creates a business document. There is a collection of business documents that you can choose from: Sales Invoice, Purchase Order, Collection Letter, etc.. Currently all of these documents follow the corporate style designed by Microspective.
-
Tip Nice to know: your info and preferences are saved and will be reused the next time you create an ERP template. When you click Finish, the Wizard creates: l l l l A Print context with one section in it; see "Print context" below and "Print sections" on page 518. One Master Page. Master Pages are used for headers and footers, for images and other elements that have to appear on more than one page, and for special elements like tearoffs. See "Master Pages" on page 537. One Media.
-
Creating the Print context You can start creating a Print template with a Wizard (see "Creating a Print template with a Wizard" on page 507), or add the Print context to an existing template (see "Adding a context" on page 499). Tip Editing PDF files in the Designer is not possible, but when they're used as a section's background, you can add text and other elements, such as a barcode, to them.
-
Initially, the (empty) master page that has been created with the Print context will be applied to all pages in the Print section, but more Master Pages can be added and applied to different pages. l l One Media is added to the template, as is visible on the Resources pane, in the Media folder. This folder can hold the company's stationery in the form of PDF files.
-
Note Your printer must support duplex for this option to work. Setting the binding style for the Print context The Print context , as well as each of the Print sections, can have its own Finishing settings. In printing, Finishing is the way pages are bound together after they have been printed. Which binding styles can be applied depends on the type of printer that you are using. To set the binding style of the Print context: 1.
-
Overprint and black overprint Normally, when two colors overlap in Print output, the underlying color is not printed. It is "knocked out", for two reasons: firstly, the underlying color may affect the top color, especially if the top color is lighter than the underlying color. Secondly, not printing an underlying color, which is not visible anyway, will save ink or toner.
-
Print sections Print templates (also called Print sections), are part of the Print context. They are meant to be printed directly to a printer or a printer stream/spool file, or to a PDF file (see "Generating Print output" on page 1531). The Print context can also be added to Email output as a PDF attachment; see "Generating Email output" on page 1560. When generating output from the Print context, each of the Print sections is added to the output document, one after the other in sequence, for each record.
-
Using stationery (Media) When the output of a Print context is meant to be printed on paper that already has graphical and text elements on it (called stationery, or preprinted sheets), you can add a copy of this media, in the form of a PDF file, to the Media folder. Media can be applied to pages in a Print section, to make them appear as a background to those pages. This ensures that elements added to the Print context will correspond to their correct location on the preprinted media.
-
To add a section to a context: l On the Resources pane, expand the Contexts folder, right-click the Print context , and then click New section. Note that the new section automatically gets the same properties as the first section.
-
Tip If you need a whole Print section to be visible in the output only under certain conditions, consider using the Conditional Print Section script wizard; see "Conditional Print sections" on page 861. You can use the Conditional Content script wizard to hide parts of the content of a section; see "Showing content conditionally" on page 856. Importing a Print section To import a section from another template, click File > Import Resources... in the menu. See: "Import Resources dialog" on page 1029.
-
output in the order in which they appear on the Resources pane, so changing the order of the sections in the Print context changes the order in which they are outputted to the final document. To rearrange sections in a context: l l On the Resources pane, expand the Print context and drag and drop sections to change the order they are in. Alternatively, on the Resources pane, right-click a section in the Print context and click Arrange.
-
Note Style sheets are applied in the order in which they are included in a section. The styles in each following style sheet add up to the styles found in previously read style sheets. When style sheets have a conflicting rule for the same element, class or ID, the last style sheet ‘wins’ and overrides the rule found in the previous style sheet. Note Style sheets that are linked to (i.e. included in) a section show a chain icon in the Resources pane (see "Resources pane" on page 1128).
-
4. l Click Resources, Disk or Url, depending on where the image is located. l l l Resources lists the images that are present in the Images folder on the Resources pane. Disk lists image files that reside in a folder on a hard drive that is accessible from your computer. Click the Browse button to select a folder (or an image in a folder). As an alternative it is possible to enter the path manually. You can give a local path (e.g. C:\Images\Test.jpg) or use the "file" protocol.
-
l Fit to page stretches the PDF to fit the page size. l Centered centers the PDF on the page, vertically and horizontally. l Absolute places the PDF at a specific location on the page. Use the Top field to specify the distance between the top side of the page and the top side of the PDF, and the Left field to specify the distance between the left side of the page and the left side of the PDF.
-
Alternatively you could write your own Control Script to set the background; see "Control Script: Setting a Print section's background" on page 963. The settings in a script take precedence over the settings made in the Print Section Properties dialog. Setting the binding style for a Print section In printing, Finishing is the binding style, or the way pages are bound together.
-
To enable Duplex or Mixplex printing: 1. On the Resources pane, expand the Print context, right-click the print section and click Sheet configuration. 2. Check Duplex to enable content to be printed on the back of each sheet. 3. When Duplex printing is enabled, further options become available. l Check Omit empty back side for Last or Single sheet to reset a page to Simplex if it has an empty back side. This changes the Duplex job into a Mixplex job.
-
The consequences of empty back sides for printing and page numbering In a Duplex job, the last page of a section may be empty since each new section starts on a new sheet. You may wonder what this means for the number of 'print clicks' and for the page numbering. Note that an empty page is defined as a page that has no content and no Master Page.
-
Although generally the same content elements can be used in all three contexts (see "Content elements" on page 664), the specific characteristics of pages make it possible to use special elements, such as page numbers; see "Page numbers " on page 531. The widow/orphan setting lets you control how many lines of a paragraph stick together, when content has to move to another page; see "Preventing widows and orphans" on page 533.
-
l On the Resources pane, right-click a section in the Print context and click Properties. For the page size, click the drop-down to select a page size from a list of common paper sizes. Changing the width or height automatically sets the page size to Custom. Margins define where your text flow will go. Static elements can go everywhere on a page, that is to say, within the printable space on a page that depends on the printer. The bleed is the printable space around a page.
-
2. Insert the promotional image or snippet in the content. Note l l Only a top-level element (for example, a paragraph that is not inside a table or div) can function as a whitespace element. Do not place the promotional image or snippet inside an absolute positioned box. Whitespacing only works for elements that are part of the text flow, not for absolute-positioned boxes. 3.
-
in the Sheet Configuration dialog, see "Applying a Master Page to a page in a Print section" on page 539) but no contents, is not included in the Content page count. l l l Content page count: This is the total number of pages in the current document that have contents, supplied by the Print section. A page that has a Master Page but no contents, is not included in the Content page count. Sheet number: The current sheet number in the document.
-
Configuring page numbers By default the page numbers are Arabic numerals (1, 2, 3, etc.) without leading zeros nor prefix, and page numbering starts with page 1 for each section. But this can be changed. To do that: 1. On the Resources pane, right-click a section in the Print context and click Numbering. 2. Uncheck Restart Numbering if you want the page numbers to get consecutive page numbers, instead of restarting the page numbering with this section.
-
Note Widows and orphans are ignored if the page-break-inside property of the paragraph is set to avoid; see "Preventing a page break" on page 536. In the entire Print context To prevent widows and orphans in the entire Print context: 1. On the menu, select Edit > Stylesheets. 2. Select the Print context. 3. Click New (or, when there are already CSS rules for paragraphs, click the selector p and click Edit). 4. Click Format. 5.
-
In tables The CSS properties widows and orphans can be used in tables to prevent a number of rows from being separated from the rest of the table. Dynamic Tables are automatically divided over several pages when needed. A Standard Table doesn't flow over multiple pages by default. Splitting a Standard Table over multiple pages requires setting the Connect-specific data-breakable attribute on all of its rows.
-
3. In the Breaks group, set the before or after property. l l Before: Sets whether a page break should occur before the element. This is equivalent to the page-break-before property in CSS; see CSS page-break-before property for an explanation of the available options. After: Sets whether a page break should occur after the element. Equivalent to the page-break-after property in CSS; see CSS page-break-after property for an explanation of the available options.
-
Master Pages In Print sections, there are often elements that need to be repeated across pages, like headers, footers and logos. In addition, some elements should appear only on specific pages, such as only the first page, or the last page, or only on pages in-between. Examples are a different header on the first page, and a tear-off slip that shows up on the last page. This is what Master Pages are used for. Master Pages can only be used in the Print context (see "Print context" on page 513).
-
applied to different pages; see "Applying a Master Page to a page in a Print section" on the next page. Importing a Master Page To import one or more Master Pages from another template, click File > Import Resources... in the menu. See: "Import Resources dialog" on page 1029. Editing a Master Page Master Pages are edited just like sections, in the workspace. To open a Master Page, expand the Master pages folder on the Resources pane, and double-click the Master Page to open it.
-
2. Next, define the margins for the header and footer. The margins for a header and footer are set in the Master Page properties. This does not change the content placement within the Master Page itself; in Master Pages, elements can go everywhere on the page. Instead, the header and footer of the Master Page limit the text flow on pages in the Print sections to which this Master Page is applied.
-
the specified Master Page on the last backside of a section if that page is empty. That page will then also be skipped from the page count unless the page numbers continue on the next section (see "Configuring page numbers" on page 533). Note that if the Omit empty back side for Last or Single sheet option (see "General options" on page 1085) is checked as well, the empty backside will not appear in the output at all and will not be counted in any case. 5.
-
For further explanation about how to apply Media to different pages, see "Applying Media to a page in a Print section" on page 544. Media will not be printed, unless you want them to; see below. Per Media, a front and back can be specified and you can specify on what kind of paper the output is meant to be printed on. This includes paper weight, quality, coating and finishing; see "Setting Media properties" below.
-
type of image file) for both the front and the back of the Media, and you can determine how the virtual stationery should be positioned on the page. This is done as follows: 1. On the Resources pane, expand the Contexts folder, expand the Media folder, rightclick the Media and click Properties. 2. Now you can change the name and page size of the Media. Note that it isn't possible to change the page size once the Media is applied to a section. Media can only be applied to sections that have the same size. 3.
-
not selected, the Select Image dialog automatically adds the filetype parameter with the file extension as its value (for example: ?filetype=pdf (if it is the first parameter) or &filetype=pdf). The filetype, page and nopreview parameters are not sent to the host; they are used internally. Therefore, URLs that rely on one of these parameters cannot be used. l With an external image, you can check the option Save with template.
-
Setting the paper's characteristics To set a Media's paper characteristics: 1. On the Resources pane, expand the Contexts folder, expand the Media folder, and right-click the Media. Click Characteristics. 2. Specify the paper's characteristics: l l l l l l l Media Type: The type of paper, such as Plain, Continuous, Envelope, Labels, Stationery, etc. Weight: The intended weight of the media in grammage (g/m2).
-
1. On the Resources pane, expand the Print context; right-click the Print section, and click Sheet configuration. 2. Optionally, check Duplex to enable content to be printed on the back of each sheet. Your printer must support duplex for this option to work. If Duplex is enabled, you can also check Tumble to duplex pages as in a calendar, and Facing pages to have the margins of the section switch alternately, so that pages are printed as if in a magazine or book. 3.
-
2. Decide which pages should have dynamically switching media: every first page in the Print section, every last page, one of the pages in between (a 'middle page'), or a single page. (Uncheck the option Same for all positions, to see all page positions.) 3. In the area for the respective sheet position, click the Edit script button next to Media. The Script Wizard appears with a standard script: results.
-
Note l l Any Virtual Stationery settings made for the Media also influence how the Media is displayed in each section (see "Setting Media properties" on page 541). Section backgrounds are rotated separately (see "Using a PDF file or other image as background" on page 523). If in the Media properties, the Virtual Stationery position is set to Absolute, any offset given by the Top and Left values will be applied after rotation.
-
HTML email that displays properly on a variety of devices and screen sizes is challenging. Building an email is not like building for the web. While web browsers comply with standards (to a significant extent), email clients do not. Different email clients interpret the same HTML and CSS styles in totally different ways.
-
Designing an Email template With the Designer you can design Email templates. It is strongly recommended to start creating an Email template with an Email Template Wizard, because it is challenging to design HTML email that looks good on all email clients, devices and screen sizes that customers use when they are reading their email.
-
Email templates: Slate and others The most obvious solution offered in the Designer is to use one of the templates provided with the Designer; see "Creating an Email template with a Wizard" on page 552. The layout of these templates has been tested and proven to look good in any email client, on any device and screen size. The Tables in these templates are nested (put inside another table) and they have no visible borders, so readers won't notice them.
-
All standard abbreviations can be found in Emmet's documentation: Abbreviations. To learn more about Emmet, please see their website: Emmet.io and the Emmet.io documentation: http://docs.emmet.io/. Preferences To change the way Emmet works in the Designer, select Window > Preferences, and in the Preferences dialog, select Emmet; see "Emmet preferences" on page 903.
-
Do not capture your email in one big image Most e-mail clients do not automatically download images, so do not capture your email in one big image. The recipient initially sees a blank message and probably deletes it right away. Do not resize images in your email Many mail clients do not support image resizing and will show the image in its original dimensions. Resize the images before you link to or embed them.
-
Email Template Wizards: l l Basic Email templates l Banded Email templates l Slate: Responsive Email templates by Litmus. Or choose Create a New Template and select the Email template. This starts the Basic Action Email wizard. Alternatively, on the File menu, click New, and: l l Select Email Template. This starts the Basic Action Email wizard.
-
l A style sheet, named context_htmlemail_styles.css, and another style sheet depending on which Template Wizard was used. The style sheets can be found in the Stylesheets folder on the Resources pane. The Wizard opens the Email section, so that you can fill it with text and other elements; see "Content elements" on page 664, "Email context" on page 556, and "Email templates" on page 558. Tip Use the Outline pane at the left to see which elements are present in the template and to select an element.
-
More than 50% of emails are opened on mobile. These five responsive HTML email templates are optimized for small screens and they look great in any inbox. They’ve been tested in Litmus and are completely bulletproof. Tip After creating the email template, click the Responsive Design View icon of the workspace to see how the email looks on different screen sizes. at the top The only thing you can set in advance for a Slate template is the color of the call-to-action button.
-
page 819. l The web address where the recipient of the email will be taken after clicking the button in the email. Type the URL in the Link field. In addition, for an Invoice email you can change the following content settings: l l Show Welcome Message. Check this option to insert a salutation and one paragraph with dummy text in the email. Detail Table Name. Type the name of a detail table to fill the lines of the invoice with data.
-
Sending email When the template is ready, you can generate Email output; See "Generating Email output" on page 1560. To test a template, you can send a test email first. This allows you to override the recipient address. Output, generated from an Email template, can have the following attachments: l The contents of the Print context, in the form of a single PDF attachment. (Compression options for PDF attachments can be specified in the Email context's properties; see "Compressing PDF attachments" below.
-
1. On the Resources pane, expand the Contexts folder; then right-click the Email context and select PDF Attachments. Alternatively, select Context > PDF Attachments on the main menu. This option is only available when editing an Email section in the Workspace. 2. Change the properties of the PDF file that will be attached when the Print context is attached to the email. Lossless is the maximum quality. Note that this will produce a larger PDF file. Uncheck this option to be able to set a lower quality.
-
An Email context can contain multiple templates. When generating output from the Email context, however, only one of the Email templates can be merged with each record. Set the 'default' Email section (see below) before generating Email output; see also "Generating Email output" on page 1560. For information about attachments see "Email attachments" on page 569.
-
Note that when the imported Email section replaces an Email section in your template, the PDF attachments settings are imported as well. (See: "Compressing PDF attachments" on page 557.) Deleting an Email template To delete an Email section: l On the Resources pane, expand the Contexts folder, expand the Email context, rightclick the name of the section, and then click Delete.
-
In order for a style sheet to be applied to a specific section, it needs to be included in that section. There are two ways to do this. Drag & drop a style sheet 1. Click and hold the mouse button on the style sheet on the Resources pane. 2. Move the mouse cursor within the Resources pane to the section to which the style sheet should be applied. 3. Release the mouse button. Using the Includes dialog 1. On the Resources pane, right-click the section, then click Includes. 2.
-
Setting a default Email template for output An Email context can contain multiple templates. When generating output from the Email context, however, only one of the Email templates can be merged with each record. To select the Email section that will be output by default: l On the Resources pane, expand the Email context, right-click a section and click Set as Default.
-
Preview mode. The To address must always be variable. This field is not used when you send a test email (see "Generating Email output" on page 1560). Note Using a variable email address requires you to load dataor a data mapping configuration first; see "Loading data" on page 833. The Email Script Wizard In addition to the drag and drop method, you can use the Email Script Wizard to add data to an email header field.
-
Email SMTP settings Simple Mail Transfer Protocol (SMTP) is the standard protocol for sending emails across the Internet. Default SMTP settings can be specified in the Preferences dialog: select Window > Preferences, expand the Email preferences and click SMTP. You can add as many presets as needed, for example for different Email Service Providers (see "Using an ESP with PlanetPress Connect" on page 1565). To do this, click the Add button at the right.
-
older encryption type). This option is ignored when port 465 is used. When you click the Restore button, the presets for a number of Email Service Providers will appear. Note When updating the software from a version prior to version 1.5, pre-existing presets will be maintained in the new version. In the Send Test Email dialog and Send Email dialog (see "Send (Test) Email" on page 1080) you will be able to choose one of the presets and adjust the settings to your needs.
-
Note By default, the Subject script targets one email section specifically. You can see this when you double-click the script on the Scripts pane. The selector of the Subject script contains the name of a particular email section, for example: html.HTML_EMAIL [section="Content"] (in this case, Content is the name of the email section). If you remove the [section=...] part from the selector, the script will work for all email sections. Subject scripts made with versions of the software prior to version 1.
-
Email addresses in the Bcc ('blind carbon copy') field will not be visible to any other recipient of the email. Alternatively, you could use the Script Wizard to create the scripts; see "The Email Script Wizard" on page 563. Sender From address A default From name and email address can be specified in the Preferences dialog: select Window > Preferences, expand the Email preferences and click General.
-
Reply To address The Reply To address is used by mail clients, when the recipient clicks the Reply To (or Reply All) button. You can type an email address directly in the Reply To field (as long as no script is present for this field). Alternatively, you can drag and drop one data field into the field, or use the Email Script Wizard (see "The Email Script Wizard" on page 563), to specify the Reply To address in a script.
-
To define a password to protect the generated PDF attachment: 1. On the Scripts pane, click the black triangle on the New button and click Email PDF password Script. A new script is added to the Scripts pane. 2. Double-click the new script to open it. 3. Select a data field and optionally, type a prefix and/or suffix. Password types PDF allows for two types of passwords to be set on a secured PDF file: a user password and owner password. The user password allows a limited access to the file (e.g.
-
Attaching the Print context and/or the Web context is one of the options in the "Send (Test) Email" on page 1080 dialog. These options are also available in the Create Email Content task in Workflow. Attaching a Context By default, when adding the Print context to an email, all Print sections are output to a single PDF file, named after the email subject, which is then attached to the email. The PDF can be protected with a password (see "Email PDF password" on page 568).
-
The easiest way is to drag and drop the desired file on the Email section. If the file is an image, you will be presented with the option to import it into the template's Resources folder. Any other file will be added to the list of attachments directly. The Attachments dialog also lets you select files and delete attachments. To open the Attachments dialog, right-click the Email section in the Resources pane and select Attachments. Alternatively, select Section > Attachments from the menu.
-
file:///C:/Attachments/. l l Data field/s. The selected data field/s will be evaluated. If a data field is empty, the entire row is skipped. Otherwise the prefix, data field value and suffix are added to the path/file name. Suffix. The suffix on the last used row should contain the file extension, including the dot (for example.pdf). For resources inside the template, refer to the folder in the Resources, e.g. 'images/file.extension' , or 'fonts/myfont.otf', etc. For any other file, give a valid URL.
-
You may want to use a custom attachment name. To learn how to do that, see "Renaming attachments" below. 6. Click OK or Apply to save your changes. Note that an Attachments script creates one single attachment. To add more attachments, you could either add Attachments scripts, or click the Expand button and edit the script. If you want to write your own email attachment scripts, there is a how-to that you may find helpful: How to add custom email attachments.
-
Web With the Designer you can create one or more Web templates and merge the template with a data set to generate personal web pages. The Web context is the Web output channel and the folder in the Designer that can contain one or more Web templates. Capture OnTheGo templates are Web templates designed for the Capture OnTheGo app (see "Capture OnTheGo" on page 602). They are stored in the Web folder as well. The Web context outputs one HTML web page.
-
You can add as many Web sections as you need; see "Web pages" on page 580. However, when output is created from the Web context, only one of the Web sections can be merged with a record; see "Generating Web output" on page 1570. Creating a Web template with a Wizard With the Designer you can design Web templates and output them through Workflow or as an attachment to an email when generating Email output.
-
l Blank l Contact Us l Jumbotron l Thank You If you don't know what template to choose, see "Web Template Wizards" on page 578 further down in this topic, where the characteristics of each kind of template are described. 3. Click Next and make adjustments to the settings. The wizard remembers the settings that were last used for a Foundation Web template. l Section: l l l Description: Enter the description of the page. This is the contents of a HTML tag.
-
l l l l A Web context with one web page template (also called a section) in it. The web page contains a Header, a Section and a Footer element with dummy text, and depending on the type of web page, a navigation bar, button and/or Form elements. Resources related to the Foundation framework (see "Web Template Wizards" on the facing page): style sheets and JavaScript files. The style sheets can be found in the Stylesheets folder on the Resources pane.
-
Web Template Wizards Foundation With the exception of the most basic one, all Web Template Wizards in the Designer make use of the Zurb Foundation front-end framework. A front-end framework is a collection of HTML, CSS, and JavaScript files to build upon. Foundation is a responsive framework: it uses CSS media queries and a mobile-first approach, so that websites built upon Foundation look good and function well on multiple devices including desktop and laptop computers, tablets, and mobile phones.
-
Creating the Web context You can start creating a Web template with a Wizard (see "Creating a Web template with a Wizard" on page 575), or add the Web context to an existing template (see "Adding a context" on page 499). When a Web template is created the following happens: l l The Web context is created and one Web page or section is added to it. You can see this on the Resources pane: expand the Contexts folder, and then expand the Web folder.
-
Style sheets are also added to the
and are used just as they would be used in a regular web page. (Also see: "Styling templates with CSS files" on page 786.) Which style sheets and JavaScript files are included, and in which order, can be decided for the Web context as a whole, as well as per Web section. To make this setting for the Web context as a whole, right-click the context on the Resources pane and select Includes. Alternatively, select Context > Includes on the main menu.
-
Adding a Web page When a Web template is created (see "Creating a Web template with a Wizard" on page 575), only one Web section is added to it. A Web context may contain various templates, but per record only one of those can be used to generate output. It is not possible to add a Web section to an existing Web context with the help of a Template Wizard.
-
l On the Resources pane, expand the Contexts folder, expand the Web context, rightclick the name of the section, and then click Delete. Warning If you don't have a backup of the template, the only way to recover a deleted section, is to click Undo on the Edit menu, until the deleted section is restored. After closing and reopening the template it is no longer possible to restore the deleted context this way.
-
string and storing the results in the attribute of an HTML element are both options in the Text Script wizard; see "Using the Text Script Wizard" on page 849. Styling and formatting a Web page The contents of a Web section can be formatted directly, or styled with Cascading Style Sheets (CSS). See "Styling and formatting" on page 785 and "Styles pane" on page 1138. In order for a style sheet to be applied to a specific section, it needs to be included in that section. There are two ways to do this.
-
Note Style sheets that are linked to (i.e. included in) a section show a chain icon in the Resources pane (see "Resources pane" on page 1128). Note Which style sheets are included can also be set for the Web context as a whole: in step 1, right-click the Web context, instead of a section. Setting a default Web page for output When generating output from the Web context, only one of the Web templates can be merged with each record.
-
the current section (or Web sections, if you have selected the Web context). Use the Include and Exclude buttons (or double-click) to move files from one list to the other. 4. Click one of the included files and use the Up and Down buttons (or drag-and-drop) to change the order in which the files are included. For more information about using JavaScript files, see "Using JavaScript" on page 597.
-
URL/target for all relative URLs in a document, you need to write a script. If you are not familiar with scripts, see "Writing your own scripts" on page 918 for an explanation of how scripts work. 1. Create a script: on the Scripts pane at the bottom left, click New. A new script appears in the list. Double-click on it to open it. 2. Change the name of the script, so that it reflects what the script does. Note Scripts can only have the same name when they are not in the same folder. 3.
-
1. On the Resources pane, expand the Web context and double-click a Web page to open it. 2. To use the Form Wizard, select the Insert > Form Wizard menu option. The Form Wizard adds a Form to the Web page including the specified fields. Alternatively, you can select Insert > Form on the menu to open a dialog that lets you set the Form's properties, validation method and location, but doesn't allow you to specify fields.
-
l Select JQuery Validation to validate using JQuery scripts. This allows you to specify stricter requirements per field and type a different message for each field to display to the user if the input is not valid. This method ensures a more consistent validation as it is browser independent. The necessary JQuery files will be added to the JavaScript folder on the Resources pane when the form is inserted. 8.
-
* If the current element is located inside another element, use the Elements drop-down to select which element is used for the insertion location. The list displays every element in the breadcrumbs, from the current selection point down to the root of the body. Note: HTML has some restrictions as to which types of elements are allowed as children of other elements. For example, a paragraph element is not allowed to have children that are block level elements - like a Div or a Table.
-
l text/plain: Spaces are converted to "+" symbols, but no special characters are encoded. Changing a Form's validation method In Connect PlanetPress Connect, there are two ways in which a Form's input can be validated: l l The Browser validation method leaves it up to the browser to validate the user input. When adding fields to the Form (see the next step) you can only make fields required and set the maximum length as an additional requirement for some fields.
-
stored in the data-custom-message attribute of the Form element, for example: Validation in Connect 1.0.0 In Connect 1.0.0, the validation method of the template was stored using the names "standard" and "custom". Standard has changed to "browser" and custom is now "jquery-validation".
-
1. Add an ID (required) and, optionally, a class. Note The ID will be copied to the name attribute of the element. The name attribute is what identifies the field to the receiving server-side script. To change the name, select the element after inserting it and type the new name on the Attributes pane. ID's and classes are also useful with regard to variable data (see "Personalizing content" on page 830) and styling (see "Styling templates with CSS files" on page 786). 2.
-
Tip For other Form elements, you can set the default value to be the value of a field in the record set; see "Specifying a default value" on the facing page. l l For a Checkbox or Radio Button you can check checked or selected respectively for the element to initially be checked/selected when the web page is shown.
-
Adding new HTML5 elements HTML5 added several new input element types that can't be found in the Designer menu. To add such an element to a template you can do the following: 1. Add an input element from the menu, for example a Text or Button. 2. Select the element in the template. 3. On the Attributes pane, select the desired input type from the Type drop-down list.
-
Note To enable submitting arrays, you need to check the Use PHP arrays or Use enhanced PHP arrays option in the HTTP Server user preferences in Workflow; see Workflow Online Help. A simple method to create arrays in the job data file is to use two pairs of square brackets in the name of the form inputs. Put the name of the array between the first pair of square brackets. Between the second pair of square brackets, define the key to which the value belongs.
-
With the Use enhanced PHP arrays option, the XML looks similar, but in this case, the value between the first pair of square brackets is expected to consist of two parts, separated by an underscore (e.g. row_0). The first part becomes the element's name. All content after the first underscore (preferably an integer) is given as an attribute of the element (e.g. ). The above HTML results in the following XML: pparker@eu.objectiflune.
-
When multiple fields with the same name are encountered, the previous value is overwritten. This way the values for unchecked checkboxes and radio buttons can be processed easily. Tip The Capture OnTheGo (COTG) plugin automatically adds a hidden field for every unchecked checkbox on a Form when the Form is submitted.
-
Adding JavaScript files to the Resources Adding a JavaScript file To add a JavaScript file to the resources: 1. Add the file: l l l Right-click the JavaScript folder on the Resources pane, and click New JavaScript. Double-click it to open and edit it. Alternatively, drag and drop the JavaScript file from the Windows Explorer to the JavaScript folder on the Resources pane. Or import one or more JavaScript files from another template; see "Import Resources dialog" on page 1029. 2.
-
There are a few advantages to using remote resources: l l These resources are not served by your server, saving on space, bandwidth and processing. Using a popular CDN takes advantage of caching - a client having visited another website using that same CDN will have the file in cache and not re-download it, making for faster load times for the client. To add a remote JavaScript: 1. Right-click the JavaScript folder on the Resources pane, and click New Remote JavaScript. 2.
-
Tip After adding the remote file, you may right-click it and select Download Resource. This allows you to maintain a central file, from which you can quickly download a copy to your template without having to copy & paste. Note that a local copy of a remote resource is a snapshot; it is not automatically kept in sync with its remote content. You can download the remote resource again to overwrite the local copy with updated content.
-
Using JavaScript in other contexts Email clients do not support JavaScript. Therefore, Email contexts cannot include JavaScript resources. When a JavaScript file is included in a Print section, the Designer itself acts as the browser. When generating Print output, it runs the JavaScript after generating the main page flow contents and the pagination, but before any Master Pages are added.
-
Capture OnTheGo With the Designer you can create Capture OnTheGo templates. COTG templates are used to generate forms for the Capture OnTheGo mobile application. For more information about the application refer to these websites: Capture OnTheGo and Capture OnTheGo in the Resource Center.
-
Tip Have a look at the Sample Project: "Sample Project: COTG Timesheets" on page 150. This wizard creates all parts of a sample COTG project, including the form. Before starting to create a COTG Form, take some time to structure the design process and to get familiar with the principles of form design, as explained in the topic "Designing a COTG Template" on page 609. Reusable forms Capture OnTheGo forms can be single-use or reusable.
-
Filling a COTG template Before inserting elements in a COTG Form, have the design ready; see "Designing a COTG Template" on page 609. In a Capture OnTheGo form, you can use special Capture OnTheGo Form elements, such as a Signature and a Barcode Scanner element. For a description of all COTG elements, see: "COTG Elements" on page 743. To learn how to use them, see "Using COTG Elements" on page 626.
-
Tip Click the Edges button on the toolbar t emporarily adds a frame to certain elements on the Design tab. These will not .Print or output. Using JavaScript COTG plugin Capture OnTheGo widgets do not function without the COTG plugin: cotg-2.x.x.js. This plugin also makes it possible to add COTG Elements dynamically, set defaults for COTG elements, react to events that occur when a user interacts with a COTG element, etc. For more information see: "Using the COTG plugin" on page 639.
-
used in any process within it. How to send the template and the corresponding data mapping configuration to the Workflow tool is explained in another topic: "Sending files to Workflow" on page 482. Next, you can start building a Workflow configuration that receives and handles the submitted data. The configuration should start with a HTTP Server Input task (see Workflow Help: HTTP Server Input) of which the HTTP action is the one specified in the COTG Form's action.
-
this: l l Using the option Get Job Data File on Submit in Connect Designer; see "Testing a Capture OnTheGo Template" on page 632. This way you don't have to create a Workflow configuration first. Once the Job Data File is received by the Connect server, a dialog appears asking where to store it. Using a Workflow configuration.
-
"Personalizing content" on page 830). Strings, base64-encoded strings and SVG data, stored in data fields using the DataMapper can be added to the template just like any other variable data; see "Variable Data" on page 846. They will show up in the template as they are. Strings and base64-encoded strings show up as strings. SVG data will be interpreted and displayed as an image. Note The Signature data returned by the COTG app (as of Android 10.6.0, iOS 10.6.0, and Windows 6.
-
Alternatively, you could add a new script on the Scripts pane and make sure that the Selector field is set to #camera. 6. Enter the following script code: results.attr("src", record.fields.photo); The name of the data field (in this case: photo) must be that of the Camera data in your data model. This script updates the attribute “src” with the field containing the base64 image. 7. Click OK to save the script and toggle to the Preview mode to see the result. You should see your image.
-
3. Creating mockups. A mockup or wire frame will help you to layout the form and allows your customer to provide feedback early in the project. This will save you a lot of time: typically it is easier to change the sketch than to rework the code. In addition, mockups provide a way to do usability testing before actually creating the form. Note that mobile devices come in various sizes. It is important to adapt the form design to these screen sizes.
-
panning, and scrolling — across a wide range of devices". (Source: Wikipedia.). With the COTG app for Android or iOS, COTG forms can be viewed on a wide variety of mobile devices, with different screen sizes. A responsive design will adapt to the size and orientation of the screen, to avoid navigation tasks like zooming in or out and scrolling horizontally.
-
Provide touch areas that are large enough. COTG forms are used on a mobile device (in the COTG app). Make sure that the user can easily tap the form elements, hyperlinks and buttons. The index finger of most adults covers an area that is between 45 and 55 pixels wide. There should be enough white space between the form inputs so the user won't accidentally put focus on the wrong element. Visually group related information. Use headers to mark a section. This makes it easier to navigate the form.
-
Foundation With the exception of the most basic one, all Web Template Wizards in the Designer make use of the Zurb Foundation front-end framework. A front-end framework is a collection of HTML, CSS, and JavaScript files to build upon. Foundation is a responsive framework: it uses CSS media queries and a mobile-first approach, so that websites built upon Foundation look good and function well on multiple devices including desktop and laptop computers, tablets, and mobile phones.
-
l l l l l l l Bill of Lading. The Bill of Lading Template is a transactional template that includes a Dynamic Table with a checkmark on each line, along with Signature and Date COTG elements. Use this wizard as a way to quickly start any new Zurb Foundation based form for Capture OnTheGo. Event Registration. The Event Registration Template is a generic registration form asking for name, phone, email, etc. Event Feedback.
-
l l l A Web context with one web page template (also called a section) in it. The web page contains an 'off-canvas' Div element, Header, a Section and a Footer element with dummy text, and depending on the type of web page, a navigation bar, button and/or Form elements. Style sheets and JavaScript files related to the COTG form itself and others related to the Foundation framework (see above). The style sheets can be found in the Stylesheets folder on the Resources pane.
-
Tip If you have started creating your Capture OnTheGo template using a COTG Template Wizard, you can find ready-made elements in the Snippets folder on the Resources pane. Foundation, the framework added by the COTG template wizards, comes with a series of features that can be very useful in COTG forms; see "Using Foundation" on the next page.
-
Using Foundation This topic explains how to use the Foundation Grid and other Foundation components in a Web Form or COTG Form. Foundation With the exception of the most basic one, all Web Template Wizards in the Designer make use of the Zurb Foundation front-end framework. A front-end framework is a collection of HTML, CSS, and JavaScript files to build upon.
-
The Grid Use the Grid to ensure the responsiveness of a form. Using the Grid essentially means building a form or web page with Div elements (a Div is a container element, see "Div" on page 733) that have the following classes: l l l row: This class identifies a Div as a horizontal block (a row) that can contain up to 12 columns. columns: This class should be used for a Div inside a Div with the class row. It identifies a Div as part of a row Div.
-
The Div elements inside the row take up 2, 4 and 6 parts of the total amount of screen size (divided in 12 parts) on a small screen. On a large screen they each take one third of the available space. If the class large-4 would have been left out, the Divs would take up 2, 4 and 6 parts of the available space, regardless of the screen size. There's more that you can do with the Grid, for example, you could center columns, or switch columns depending on the screen size they are viewed on.
-
l l An Off-Canvas menu lets the user navigate between level 4 headings (
) in a Web page or form. Capture OnTheGo Template wizards offer the option to add this menu automatically. Switches are toggle elements that switch between an Off and On state on tap or click. They make use of checkbox inputs (or radio buttons) and require no javascript. Their size can be adapted, to make them easy to use on a touch screen. For a full overview and explanation of all Foundation components (v.
-
scanning. Camera The Camera element adds a group of buttons to capture or select an image. Once the image is selected via the camera or the device's library (aka "gallery"), it is saved within the Form data. When the form is submitted, the image is sent in a base64-encoded string format. To learn how to add Camera data to a template, see "Adding Camera data to the template" on page 608. The Camera element has a number of options, of which most can be set in the Design view.
-
properties, and then check Allow annotations. Clicking (or rather, touching) the image will bring up the annotation dialog. Annotations can be made in a Marker (semi-transparent) or Pencil (solid) style, in different colors and with different widths. Annotations are submitted in SVG format by a hidden input added to the Camera element. The name of that input is the ID of the Camera element, followed by "-note-data", for example camera1-note-data.
-
How to use the captured or selected image in a template After a user has submitted the form and the data has been extracted, you may want to display the captured or selected image in a Designer template, for example in a letter or on a web page. To do this: 1. Load the data mapping configuration (or at least the data model). 2. Insert a dummy image in the template. 3. Right-click the dummy image and select Dynamic Image. The Text Script Wizard appears. 4.
-
Document ID The Document ID element retrieves the Document ID of the form currently viewed by the app. You could put the Document ID in a hidden input, so that when the form is submitted, the Document ID is submitted as well. A Document ID can be used on the server side to check (in the Connect database) if the data has already been submitted. Fields Table The Fields Table element adds a table with two rows, a Delete button at the end of the first row and an Add button at the end of the second row.
-
Image & Annotation The Image & Annotation element is meant to be used with an image that needs input from the user. When inserting an Image & Annotation element you have to select the image. The user can simply click (or rather, touch) the image to bring up the annotation dialog. Annotations can be made in a Marker (semi-transparent) or Pencil (solid) style, in different colors and with different widths. Annotations are submitted in SVG format by a hidden input.
-
containing box in a template. With previous versions of the app, the format of returned signatures could vary. Time and Formatted Time The Time element and the Formatted Time element display the current time on the device when the form is first opened. When the element is touched, a time selector appears so the user can modify this time. The Formatted Time element displays times in a format that depends on the locale of the device on which the user is viewing the form.
-
1. Add an ID (required) and, optionally, a class. Note The ID will be copied to the name attribute of the element. The name attribute is what identifies the field to the receiving server-side script. To change the name, select the element after inserting it and type the new name on the Attributes pane. ID's and classes are also useful with regard to variable data (see "Personalizing content" on page 830) and styling (see "Styling templates with CSS files" on page 786). 2.
-
The Foundation JavaScript files and style sheets will not be added. You only get those automatically when you start creating a COTG template with a template wizard. (See: "Using Foundation" on page 617.) Element specific settings After inserting certain COTG elements, such as the Camera element, some important settings have to be made. These will appear when you right-click the element and select it from the short-cut menu.
-
Tip Click the Edges button on the toolbar t emporarily adds a frame to certain elements on the Design tab. These will not .Print or output. How to make COTG elements required To make a COTG element required, or to change the validation of a COTG Form, right-click the element and choose Validation settings. Set the Form's validation method to jQuery and set the requirements and a message per field. For an explanation see "Changing a Form's validation method" on page 754.
-
Grouping data using arrays In a Connect solution, when a Web Form or COTG Form is submitted, there is a Workflow process that receives the data and creates a job data file (which is an XML file). Having arrays in the job data file greatly simplifies creating a data mapping configuration and looping over data in Designer scripts. Here's how to group data in the HTML so that they get submitted as arrays.
-
253 dent 361 341 dent With the Use enhanced PHP arrays option, the XML looks similar, but in this case, the value between the first pair of square brackets is expected to consist of two parts, separated by an underscore (e.g. row_0). The first part becomes the element's name. All content after the first underscore (preferably an integer) is given as an attribute of the element (e.g. ).
-
Getting the status of unchecked checkboxes and radio buttons Unchecked checkboxes and radio buttons are not submitted (as per standard HTML behavior), so how to get the state of those checkboxes and radio buttons? A common approach to get the state of unchecked checkboxes and radio buttons is to add a hidden field to the Form with the same name as the checkbox or radio button, for example: Whe
-
on page 634). However, remember that COTG Form elements are only functional in the COTG app, so they won't submit any data. l Within the default browser on your computer. Click the Preview HTML button in the toolbar. This opens your operating system’s default browser and displays the form in that context. Tip In the Designer, you can test the responsiveness of a form using the Responsive Design button at the top right of the workspace. Some browsers also let you test the responsiveness of a form.
-
Enter the appropriate information in the Send Test dialog (see "Send COTG Test" on page 1079). Click Finish to send the document. It should automatically appear in the app's Repository for 4 days from the moment it is sent. Once downloaded it remains accessible in the app's Library for 2 days. Tip To manually delete a test template from the app's Library, swipe it to the left.
-
right-click HTTP/Soap Server and start it. l In the Designer menu Window > Preferences > Web, the Workflow URL has been set to the correct host. The default is http://127.0.0.1:8080/_getSampleFormData_. This points to an internal process of the Workflow component running at that host. If these conditions are met, you can get the XML file as follows: 1. Open the Form in the Designer, toggle to Live mode and fill out the form.
-
Standard Form input dummy data values Input Dummy Value Text "Lorem ipsum dolor sit amet" Textarea (multi-line text field) "Lorem ipsum dolor sit amet" Email "pparker@localhost.com" Number random integer Password 1234567890 URL "http://www.localhost.com" Checkbox Checkboxes in Dynamic Tables and in the Fields Table control (time sheet) are checked. Radio button Selects the first radio button that is not disabled in each radio group.
-
Input Dummy Value tion widget Date Picker (formatte d and standar d) Today's date* TimePic ker (formatte d and standar d) Now* Device Info widget " {"available":true,"platform":"Android","version":"9.9.9","uuid":"17206724b80774 91","cordova":"3.6.4","model":"Connect Designer"}" User Account widget "user@localhost.com" Locale widget en-US * Note that the formatted date and time can be different from the values that the COTG app provides.
-
Get submitted data via email Getting submitted data via email requires the Form's action to be set to a test URL that contains an API Key. You can obtain an API Key as follows. 1. Go to http://learn.objectiflune.com/. 2. Create an account, or log in to your account. 3. Go to your Profile Page, and click the API Key link. Now, when creating or editing a COTG Form, you can use the API Key in the Form's action: 1. Select the Form (see "Selecting an element" on page 669). 2.
-
Using the COTG plugin A Capture OnTheGo (COTG) Form may contain special COTG input elements, like a Signature, Geolocation, or Camera element. These elements do not function without the COTG JavaScript library. It is this library that links the controls with hardware features on the mobile device. The COTG JavaScript library offers options and custom events for COTG widgets to support event-based programming in Capture OnTheGo Forms.
-
Adding the plugin When you create a template with a COTG Template Wizard (see "Capture OnTheGo template wizards" on page 612), the Designer automatically adds the jQuery library v. 3.5 and the COTG library: cotg-2.1.0.js. This also happens when you add a Capture OnTheGo (COTG) element to a template that you didn't start with a COTG template wizard.
-
Example The following code sets the default timeout and accuracy for Geolocation objects. and the default maximum height and width for Camera widgets. $.fn.cotgGeolocation.defaults.timeout = 6000; // 6 secs $.fn.cotgGeolocation.defaults.enableHighAccuracy = true; $.fn.cotgPhotoWidget.defaults.width = 1024; $.fn.cotgPhotoWidget.defaults.height = 768; $.fn.cotgPhotoWidget.defaults.quality = 60; Reacting to, or triggering, widget events The new COTG plugin introduces custom events for COTG controls.
-
$('#date1').trigger("show-date-picker.cotg", new Date("2018 01")); }); }); Dynamically adding COTG widgets Capture OnTheGo (COTG) widgets can be added to a Form dynamically, via jQuery. For example: a new Camera element could be added when the user clicks an Add button. This topic explains how to implement this. It is assumed that you have a basic understanding of HTML forms, CSS, JavaScript, and jQuery.
-
}); }); Creating the widget Now you can start writing the code that constructs, adds and initializes the widget. This code has to be based on jQuery. Constructing the HTML A widget basically is an HTML element with certain attributes and contents. The HTML structure of a widget can be seen on the Source tab after adding the widget to a Form in the Designer. In code, reconstruct the HTML. Make sure to give the new element an ID.
-
Optionally, while initializing an element, you can make settings for this specific element. These settings get prevalence over the options already specified in the HTML and over the default settings specified in the COTG plugin. The code snippet below initializes a new Camera element (with the ID myCamera) with a number of settings: $('#myCamera').
-
addCameraWidget(cameraID); }); }); function getCameraIndex(){ return $("input.camera-dyn").length; } function addCameraWidget(cameraID, value) { if(typeof value == 'undefined') { value = ''; } var html = ''; $('#cameras').
-
Note When user of the COTG app clicks or touches the Submit button in a Form, the name and value of form elements are submitted. Normally, the name and value of an unchecked Checkbox or Radio Button would not be submitted, but in Connect, they are. Connect uses the workaround described in the following topic: "Getting the status of unchecked checkboxes and radio buttons" on page 632.
-
The below procedure describes how to use Camera data as the source of an image inside a
container. The benefit of this approach is that the image automatically scales to the size of the container. 1. Click the Insert Inline Box icon on the toolbar. The Insert Inline Box dialog appears. 2. Enter an ID for the box (anything will do, as long as it helps you identify the box) and click OK. The box is added to the text flow and can be resized if needed. 3.
-
With OL Connect 2021.1 the COTG library has been updated to version 2.1.0 to support nested fields tables in COTG Fields Table elements. This also fixed an issue with the COTG Camera Widget that occurred when it was used in a COTG Fields Table. How to use the COTG plugin is explained in the following topic: "Using the COTG plugin" on page 639. To learn how to create widgets in code, see "Dynamically adding COTG widgets" on page 642 and "Saving and restoring custom data and widgets" on page 645.
-
Optional. An array containing the desired settings, e.g. {quality: 50, height: 1024, width: 1024}. For any unspecified options the default settings will be used. Initialize the new Camera element with any settings that you want to be different from the defaults. Example: $('#myCamera').cotgPhotoWidget({quality: 50, height: 1024}); How to change the default settings is explained in another topic: "Changing default settings for widgets" on page 640.
-
Option Description Type Default no loss from file compression. allowannotations Adds an Image & Annotation widget to edit the picture. Boolean false allowdeskew Allows the user to perform a perspective cropping after taking or selecting a picture. Boolean false addtimestamp Adds a time stamp Boolean false stampFormat The date format. For all possible formats see Cordova documentation. 'L' stands for localized date and time.
-
Event Description state.cotg restorestate.cotg Restores the state of the widget when the form is reopened in the COTG app, after the app has restored previously entered values of static input fields. The Camera broadcasts the following events. Event Description clear.cotg Fired after the user has clicked the Clear button. set.cotg Fired after the user has taken or selected a picture.
-
Event Description show-datepicker.cotg Opens the Date picker. Optionally, you can provide a date (as a Date object) for the Date picker to be opened with, for example: $('#date1').trigger("show-date-picker.cotg", new Date("2018-01-01")); Device Info cotgDeviceInfo() Initializing a Device Info element puts information about the device (phone or tablet) that displays the form, in the hidden input of the element. Example: $('#myDeviceInfo').
-
Events The Document ID element listens for the following event. Event Description clear.cotg Removes the Document ID. The Document ID element broadcasts the following event. Event Description set.cotg This event is fired during initialization of the element, after setting its value to the current Document ID. Fields Table The Fields Table element itself is just a table, so it doesn't have to be initialized.
-
Call cotgGeolocation([options]) on the new Geolocation element with any settings that you want to be different from the defaults. Example: $('#myGeolocation').cotgGeolocation({timeout: 6000}); How to change the default settings is explained in another topic: "Changing default settings for widgets" on page 640. Option Description Type Default enableHighAccuracy By default, the device attempts to retrieve a position using networkbased methods.
-
Event Description update.cotg Sets the element to the current geolocation. Image & Annotation cotgNoteOnImage() Initializing a new Image & Annotation element prepares it for user interaction. Example: $('#myNoteOnImage').cotgNoteOnImage(); Note To use this element with a Camera widget instead of a static image, you only have to initialize the Camera widget with the allowannotations option set to true. The Camera widget will automatically initialize the Image & Annotation widget.
-
Event Description set.cotg Fired after an annotation has been made. Locale cotgLocale() Initializing a new Locale element sets it to the device's locale. Example: $('#myLocale').cotgLocale(); Events The Locale element listens for the following event. Event Description clear.cotg Removes the Locale data. The Locale element broadcasts the following event. Event Description set.cotg This event is fired during initialization of the element, after setting its value to the current locale.
-
Event Description clear.cotg Removes the Repositiory ID data. The Repository ID element broadcasts the following event. Event Description set.cotg This event is fired during initialization of the element, after setting its value to the current Repository ID. Signature cotgSignature() Initializing a new Signature element prepares it for user interaction. Example: $('#mySignature').cotgSignature(); Events The Signature element listens for the following custom events. Field Description clear.
-
Field Description $(“#signature”).trigger(“set.cotg”, “”); The Signature element broadcasts the following events. Field Description set.cotg This event is fired after a user has entered a signature and clicked the Done button of the Signature window on the device. clear.cotg Fired after a user has clicked the Done button of the Signature window without entering a signature. draw.cotg Fired each time the signature is drawn on the form (by the app, not by the user; e.g. after a set.
-
Event Description show-timepicker.cotg Opens the Time Picker. If no time is provided (specified in a Date object), the current time will be shown. User Account cotgUserAccount() Initializing a new User Account element puts the account of the current user in the hidden input of this element. Example: $('#myUser').cotgUserAccount(); Events The User Account element listens for the following custom event. Event Description clear.cotg Removes the User Account data.
-
"Selecting an element" on page 669, "Attributes" on page 667 and "Styling and formatting an element" on page 670. ID's and classes are particularly useful with regard to variable data (see "Personalizing content" on page 830) and styling (see "Styling templates with CSS files" on page 786). When you add elements, such as text, images or a table, to the content of a template, you are actually constructing an HTML file.
-
l l Article, Section, Header, Footer, Nav and Aside are HTML5 semantic elements; see https://www.w3schools.com/html/html5_semantic_elements.asp Other HTML elements: Heading (H1 - H6), Address and Pre To quickly change a paragraph into a Heading, place the cursor inside of it, or select the paragraph (see: "Selecting an element" on page 669). Then select the appropriate element, either on the Format menu, or from the 'Element type' drop-down on the toolbar.
-
Many video courses and hands-on courses about HTML (and CSS) are offered on the Internet as well, some for free. Go, for example, to www.codeschool.com or www.codeacademy.com and look for HTML (and CSS) courses. Attributes ID and class Every element in the content of a template can have an ID and a class. ID's and classes are particularly useful with regard to variable data (see "Personalizing content" on page 830) and styling (see "Styling templates with CSS files" on page 786).
-
Changing attributes via script Many attributes can be changed via the user interface. Another way to change attributes is by using a script. Any of the Script Wizards can produce a script that changes an attribute of an HTML element. Set the Options in the Script Wizard to Attribute, to output the script's results to the value of a specific attribute. See "Using the Text Script Wizard" on page 849.
-
l l After element inserts it after the element in which the cursor is currently located. For example if the cursor is within a paragraph, the insertion point will be after the end tag of the paragraph (
).* Replace inserts it in place of the currently selected element. (This option is not available when inserting content in a Master Page.) * If the current element is located inside another element, use the Elements drop-down to select which element is used for the insertion location.
-
Breadcrumbs show the HTML tag of the clicked element, as well as the HTML tags of 'parent elements': elements inside of which the clicked element is located. The clicked element is at the end of the line. Elements with classes or IDs show these details next to them, for instance div #contents > ol.salesitems > li ~contents. Click any of the elements in the Breadcrumbs to select that element. If an element is selected in the Breadcrumbs and the Backspace key is pressed, that element is deleted.
-
Format elements via Cascading Style Sheets (CSS) It is highly recommended to use style sheets in templates right from the start. Even more so if the communications are going to be output to different output channels, or if they consist of different sections (for example, a covering letter followed by a policy). Using CSS with templates allows a consistent look and feel to be applied.
-
4. Check the option Absolute to insert the barcode in an absolute-positioned box inside the
of the HTML, but outside other elements. (This option is not available in Email sections.) Alternatively, use the Location drop-down to select where to insert the Barcode. l l l l l l At cursor position inserts it where the cursor is located in the template. Before element inserts it before the HTML element in which the cursor is currently located.
-
Note For barcodes that require a Checksum, the Designer can calculate a Checksum if that isn't provided by your data. In that case the field should contain the required value minus the Checksum. To include a calculated Checksum in the barcode value, edit the barcode properties after adding the barcode to the template; see below. 6. Click OK to close the dialog. In the template the barcode shows up as a gray box. The associated barcode script is added to the Scripts pane.
-
To change the barcode type or the barcode's properties such as the scale and color, open the Barcode properties dialog: right-click the barcode (on the Design tab in the Workspace) and select Barcode on the shortcut menu. The barcode properties set via the properties dialog are written to the data-params attribute on the barcode element in JSON format. (To see this, select the barcode and open the document in the Source view.) Click the barcode type below for information about its properties.
-
l "MSI" on page 709 l "PDF417" on page 711 l "POSTNET" on page 713 l "QR Code" on page 714 l "Royal Mail 2D Mailmark" on page 717 l "Royal Mail 4-State (CBC)" on page 719 l Royal Mail 4-State Mailmark C, Royal Mail 4-State Mailmark L, see "Royal Mail 4-State Mailmark C, Royal Mail 4-State Mailmark L" on page 722 l "Swiss QR Code" on page 724 l UPC-A, UPC-E, see "UPC-A, UPC-E, EAN-8, EAN-13" on page 726 l USPS IMb, see "Australia Post, Japan Post, KIX, USPS IMb" on page 728 l "USPS IMpb"
-
Height, width and spacing The height, width and spacing of the barcode are all measured in pixels (38 dpi). l Bar height: The height of the (shorter) bars. l Extended bar height: The total height of the extended bars. l Bar width: The width of the bars. l Spacing: The distance between the bars. Scale Defines if and how the rendered barcode is scaled in relation to the parent element: l l None: The barcode is rendered based on the module width.
-
The barcode can be added either using the Barcode toolbar button or through selecting Insert > Barcode on the menu; see "Adding a Barcode" on page 671. Initially the barcode will have the barcode type's default properties. To change those properties, such as the scale and color, open the Barcode properties dialog: right-click the barcode (on the Design tab in the Workspace) and select the Barcode... option in the context menu.
-
Rune When set to a value between 0 and 255, an Aztec Rune corresponding to the selected value is created. Set the Rune to -1 to disable this feature. Scale Defines if and how the rendered barcode is scaled in relation to the parent element: l l None: The barcode is rendered based on the module width. Proportional: The barcode is stretched up to where it fits either the width or height of the parent box, whichever requires the less stretching.
-
Codabar Codabar is one of the barcode types that can be added to a template. The barcode can be added either using the Barcode toolbar button or through selecting Insert > Barcode on the menu; see "Adding a Barcode" on page 671. Initially the barcode will have the barcode type's default properties. To change those properties, such as the scale and color, open the Barcode properties dialog: right-click the barcode (on the Design tab in the Workspace) and select the Barcode... option in the context menu.
-
Human Readable Message When this option is checked, PlanetPress Connect shows a human readable text below or above the barcode, as defined using the Text Position, using the specified font and font size. The font size is given in points (pt). Color The Color group allows you to choose a different Barcode color (instead of black) and Background color (instead of white), by typing a hexadecimal color value (see for example w3school's color picker).
-
Barcode properties This topic lists the properties of the following barcode types : l Code 11 l Code 93 l Industrial 2 of 5 l Interleaved 2 of 5 l Matrix 2 of 5 For the properties of other barcode types, see "Barcode type and properties" on page 673. Module width Specifies the width of the narrow bars in centimeters. Changing this value to a higher value will make the barcode bigger when Scale is set to None.
-
w3school's color picker). When black is a composite of CMYK or RGB values, it may incur a color click charge on some printers. Check the Output in Grayscale option to make sure that pure black is used. Output format Defines how the barcode is output on the page. There are two possible formats: l l SVG: Vector format. This is usually of higher quality, but may take longer to generate and is not compatible with Email output. PNG: Binary rasterized format.
-
Inter Character Gap Two adjacent characters are separated by an inter-character gap. A value of 1 means that the separator will have the same length as the width of the narrow bars (in centimeters). Scale Defines if and how the rendered barcode is scaled in relation to the parent element: l None: The barcode is rendered based on the module width. l Fit to box: The barcode is stretched to fit the parent box in both width and height.
-
Code 39 extended Code 39 extended is one of the barcode types that can be added to a template. The barcode can be added either using the Barcode toolbar button or through selecting Insert > Barcode on the menu; see "Adding a Barcode" on page 671. Initially the barcode will have the barcode type's default properties. To change those properties, such as the scale and color, open the Barcode properties dialog: right-click the barcode (on the Design tab in the Workspace) and select the Barcode...
-
Add Checksum When checked, PlanetPress Connect will calculate a Checksum character and add that to the result of the Barcode script. If the value to be encoded is longer than 10 digits, a second check character will be calculated. Tilde processing Check this option to process tilde (~) characters in the data as special characters. (See the Java4less Barcodes Guide to learn what the tilde character can be used for.
-
Code 11, Code 93, Industrial 2 of 5, Interleaved 2 of 5, Matrix 2 of 5 Code 11, Code 93, Industrial 2 of 5, Interleaved 2 of 5, and Matrix 2 of 5 are a few of the barcode types that can be added to a template. The barcode can be added either using the Barcode toolbar button or through selecting Insert > Barcode on the menu; see "Adding a Barcode" on page 671. Initially the barcode will have the barcode type's default properties.
-
Add Checksum When checked, PlanetPress Connect will calculate a Checksum character and add that to the result of the Barcode script. If the value to be encoded is longer than 10 digits, a second check character will be calculated. Human Readable Message When this option is checked, PlanetPress Connect shows a human readable text below or above the barcode, as defined using the Text Position, using the specified font and font size. The font size is given in points (pt).
-
Barcode properties This topic lists the properties of the Code 93 extended barcode. For the properties of other barcode types, see "Barcode type and properties" on page 673. Module width Specifies the width of the narrow bars in centimeters. Changing this value to a higher value will make the barcode bigger when Scale is set to None. Scale Defines if and how the rendered barcode is scaled in relation to the parent element: l None: The barcode is rendered based on the module width.
-
Color The Color group allows you to choose a different Barcode color (instead of black) and Background color (instead of white), by typing a hexadecimal color value (see for example w3school's color picker). When black is a composite of CMYK or RGB values, it may incur a color click charge on some printers. Check the Output in Grayscale option to make sure that pure black is used. Output format Defines how the barcode is output on the page. There are two possible formats: l l SVG: Vector format.
-
Code set Set of characters to be used: l A: ASCII characters 00 to 95 (0–9, A–Z and control codes), special characters, and FNC 1–4 l B: ASCII characters 32 to 127 (0–9, A–Z, a–z), special characters, and FNC 1–4 l C: 00–99 (encodes each two digits with one code) and FNC 1 In Auto mode, the barcode generator will automatically select the correct encoding mode (set A, B or C) according to the input data.
-
Human Readable Message When this option is checked, PlanetPress Connect shows a human readable text below or above the barcode, as defined using the Text Position, using the specified font and font size. The font size is given in points (pt). Color The Color group allows you to choose a different Barcode color (instead of black) and Background color (instead of white), by typing a hexadecimal color value (see for example w3school's color picker).
-
Barcode properties This topic lists the properties of the Data Matrix barcode. For the properties of other barcode types, see "Barcode type and properties" on page 673. Note Tilde characters in the data are processed as special characters (see the Java4less Barcodes Guide to learn what the tilde character can be used for). Any tilde that needs to be included in the output must be escaped by adding another tilde (either "~~", or "7E7E" if the Hex input option is enabled).
-
Preferred format Use the drop-down to select the size of the Data Matrix. Scale Defines if and how the rendered barcode is scaled in relation to the parent element: l l None: The barcode is rendered based on the module width. Proportional: The barcode is stretched up to where it fits either the width or height of the parent box, whichever requires the less stretching. Tilde processing Check this option to process tilde (~) characters in the data as special characters.
-
UPC-A, UPC-E, EAN-8, EAN-13 UPC-A, UPC-E, EAN-8 and EAN-13 are a few of the barcode types that can be added to a template. The barcode can be added either using the Barcode toolbar button or through selecting Insert > Barcode on the menu; see "Adding a Barcode" on page 671. Initially the barcode will have the barcode type's default properties.
-
l Type: The supplement type can be 2-digit (originally used to indicate the edition of a magazine or periodical) or 5-digit (used to indicate the suggested retail price for books). In case this option is set to None, and the data includes digits for the 2 or 5 supplement, the supplement data will be skipped and the additional barcode will not be rendered. Note When the chosen supplement type doesn't match the data, the supplement data will be skipped and the additional barcode will not be rendered.
-
GS1 DataMatrix GS1 DataMatrix is one of the types of barcodes that can be added to a template; see "Barcode" on page 671. The barcode can be added either using the Barcode toolbar button or through selecting Insert > Barcode on the menu; see "Adding a Barcode" on page 671. Initially the barcode will have the barcode type's default properties.
-
l None: The barcode is rendered based on the module width. l Fit to box: The barcode is stretched to fit the parent box in both width and height. Add Checksum When checked, PlanetPress Connect will calculate a Checksum character and add that to the result of the Barcode script. If the value to be encoded is longer than 10 digits, a second check character will be calculated. Tilde processing Check this option to process tilde (~) characters in the data as special characters.
-
Color The Color group allows you to choose a different Barcode color (instead of black) and Background color (instead of white), by typing a hexadecimal color value (see for example w3school's color picker). When black is a composite of CMYK or RGB values, it may incur a color click charge on some printers. Check the Output in Grayscale option to make sure that pure black is used. Output format Defines how the barcode is output on the page. There are two possible formats: l l SVG: Vector format.
-
Scale Defines if and how the rendered barcode is scaled in relation to the parent element: l None: The barcode is rendered based on the module width. l Fit to box: The barcode is stretched to fit the parent box in both width and height. Add Checksum When checked, PlanetPress Connect will calculate a Checksum character and add that to the result of the Barcode script. If the value to be encoded is longer than 10 digits, a second check character will be calculated.
-
l l SVG: Vector format. This is usually of higher quality, but may take longer to generate and is not compatible with Email output. PNG: Binary rasterized format. This has a slightly lower quality than SVG but is usually generated faster and will display properly in Email output. Code 11, Code 93, Industrial 2 of 5, Interleaved 2 of 5, Matrix 2 of 5 Code 11, Code 93, Industrial 2 of 5, Interleaved 2 of 5, and Matrix 2 of 5 are a few of the barcode types that can be added to a template.
-
l None: The barcode is rendered based on the module width. l Fit to box: The barcode is stretched to fit the parent box in both width and height. Add Checksum When checked, PlanetPress Connect will calculate a Checksum character and add that to the result of the Barcode script. If the value to be encoded is longer than 10 digits, a second check character will be calculated.
-
Initially the barcode will have the barcode type's default properties. To change those properties, such as the scale and color, open the Barcode properties dialog: right-click the barcode (on the Design tab in the Workspace) and select the Barcode... option in the context menu. Note that barcodes of these types process tilde characters (~) in the data as special characters. See the Java4less Barcodes Guide to learn what the tilde character can be used for.
-
Human Readable Message When this option is checked, PlanetPress Connect shows a human readable text below or above the barcode, as defined using the Text Position, using the specified font and font size. The font size is given in points (pt). Color The Color group allows you to choose a different Barcode color (instead of black) and Background color (instead of white), by typing a hexadecimal color value (see for example w3school's color picker).
-
Note that barcodes of these types don't process tilde characters (~) in the data as special characters. Barcode properties This topic lists the properties of the barcode types Australia Post, Japan Post, KIX and UPS IMb. For the properties of other barcode types, see "Barcode type and properties" on page 673. Height, width and spacing The height, width and spacing of the barcode are all measured in pixels (38 dpi). l Bar height: The height of the (shorter) bars.
-
l PNG: Binary rasterized format. This has a slightly lower quality than SVG but is usually generated faster and will display properly in Email output. Australia Post, Japan Post, KIX, USPS IMb Australia Post, Japan Post, KIX and USPS IMb are some of the types of barcodes that can be added to a template; see "Barcode" on page 671. In PlanetPress Connect versions prior to 2019.2 the USPS IMb barcode was called "OneCode".
-
l l None: The barcode is rendered based on the module width. Proportional: The barcode is stretched up to where it fits either the width or height of the parent box, whichever requires the less stretching. Color The Color group allows you to choose a different Barcode color (instead of black) and Background color (instead of white), by typing a hexadecimal color value (see for example w3school's color picker).
-
l Code 11 l Code 93 l Industrial 2 of 5 l Interleaved 2 of 5 l Matrix 2 of 5 For the properties of other barcode types, see "Barcode type and properties" on page 673. Module width Specifies the width of the narrow bars in centimeters. Changing this value to a higher value will make the barcode bigger when Scale is set to None. Scale Defines if and how the rendered barcode is scaled in relation to the parent element: l None: The barcode is rendered based on the module width.
-
When black is a composite of CMYK or RGB values, it may incur a color click charge on some printers. Check the Output in Grayscale option to make sure that pure black is used. Output format Defines how the barcode is output on the page. There are two possible formats: l l SVG: Vector format. This is usually of higher quality, but may take longer to generate and is not compatible with Email output. PNG: Binary rasterized format.
-
Tilde processing Check this option to process tilde (~) characters in the data as special characters. (See the Java4less Barcodes Guide to learn what the tilde character can be used for.) The tilde is expected to be followed by the 'd' character and 3 digits representing an ASCII character: ~dNNN . For example, ~d013 represents a carriage return. Note that with this option checked, any tilde that needs to be included in the output must be escaped by adding another tilde: ~~.
-
Module width Specifies the width of the narrow bars in centimeters. Changing this value to a higher value will make the barcode bigger when Scale is set to None. Scale Defines if and how the rendered barcode is scaled in relation to the parent element: l None: The barcode is rendered based on the module width. l Fit to box: The barcode is stretched to fit the parent box in both width and height.
-
l l SVG: Vector format. This is usually of higher quality, but may take longer to generate and is not compatible with Email output. PNG: Binary rasterized format. This has a slightly lower quality than SVG but is usually generated faster and will display properly in Email output. PDF417 PDF417 is one of the types of barcodes that can be added to a template; see "Barcode" on page 671.
-
Nr. of Columns The number of data columns can vary from 3 to 30. Nr. of Rows A PDF417 bar code can have anywhere from 3 to 90 rows. Bar height Defines the height of the bars for a single row measured in pixels drawn. Compact Check this option to use Compact PDF417 instead of the PDF417 barcode. This shortened form of the PDF417 barcode is useful where the space for the symbol is restricted.
-
When black is a composite of CMYK or RGB values, it may incur a color click charge on some printers. Check the Output in Grayscale option to make sure that pure black is used. Output format Defines how the barcode is output on the page. There are two possible formats: l l SVG: Vector format. This is usually of higher quality, but may take longer to generate and is not compatible with Email output. PNG: Binary rasterized format.
-
Scale Defines if and how the rendered barcode is scaled in relation to the parent element: l None: The barcode is rendered based on the module width. l Fit to box: The barcode is stretched to fit the parent box in both width and height. l Proportionally: The barcode is stretched up to where it fits either the width or height of the parent box, whichever requires the less stretching.
-
Initially the barcode will have the barcode type's default properties. To change those properties, such as the scale and color, open the Barcode properties dialog: right-click the barcode (on the Design tab in the Workspace) and select the Barcode... option in the context menu. Instead of using the Script wizard (see "Adding a Barcode" on page 671) you could write your own script to get the data for the QR Code. Barcode properties This topic lists the properties of the QR barcode.
-
Correction level Part of the robustness of QR codes in the physical environment is their ability to sustain 'damage' and continue to function even when a part of the QR code image is obscured, defaced or removed. A higher correction level duplicates data within the QR Code to that effect, making it larger. FNC Use the drop-down to either disable FNC or select a FNC option: l l l No: No FNC option.
-
Color The Color group allows you to choose a different Barcode color (instead of black) and Background color (instead of white), by typing a hexadecimal color value (see for example w3school's color picker). When black is a composite of CMYK or RGB values, it may incur a color click charge on some printers. Check the Output in Grayscale option to make sure that pure black is used. Output format Defines how the barcode is output on the page. There are two possible formats: l l SVG: Vector format.
-
Barcode properties This topic lists the properties of the barcode type Royal Mail 2D Mailmark. For the properties of other barcode types, see "Barcode type and properties" on page 673. Module width The recommendation is to print these barcodes with a module size of 0.5 mm, which equates to 6 dots when printed at 300dpi. The maximum module size for printing is 0.7 mm. Preferred version Use the drop-down to select the size of the barcode, in a number of modules.
-
Output format Defines how the barcode is output on the page. There are two possible formats: l l SVG: Vector format. This is usually of higher quality, but may take longer to generate and is not compatible with Email output. PNG: Binary rasterized format. This has a slightly lower quality than SVG but is usually generated faster and will display properly in Email output.
-
Scale Defines if and how the rendered barcode is scaled in relation to the parent element: l l None: The barcode is rendered based on the module width. Proportional: The barcode is stretched up to where it fits either the width or height of the parent box, whichever requires the less stretching. Add Checksum When checked, PlanetPress Connect will calculate a Checksum character and add that to the result of the Barcode script.
-
Royal Mail 4-State Mailmark C, Royal Mail 4-State Mailmark L Royal Mail 4-State Mailmark C and Royal Mail 4-State Mailmark L are some of the types of barcodes that can be added to a template; see "Barcode" on page 671. The barcode can be added either using the Barcode toolbar button or through selecting Insert > Barcode on the menu; see "Adding a Barcode" on page 671. Initially the barcode will have the barcode type's default properties.
-
Color The Color group allows you to choose a different Barcode color (instead of black) and Background color (instead of white), by typing a hexadecimal color value (see for example w3school's color picker). When black is a composite of CMYK or RGB values, it may incur a color click charge on some printers. Check the Output in Grayscale option to make sure that pure black is used. Output format Defines how the barcode is output on the page. There are two possible formats: l l SVG: Vector format.
-
l Bar height: The height of the (shorter) bars. l Extended bar height: The total height of the extended bars. l Bar width: The width of the bars. l Spacing: The distance between the bars. Scale Defines if and how the rendered barcode is scaled in relation to the parent element: l l None: The barcode is rendered based on the module width. Proportional: The barcode is stretched up to where it fits either the width or height of the parent box, whichever requires the less stretching.
-
Swiss QR Code The Swiss QR Code is a specific sub-set of QR barcode standards and is one of the several types of barcodes that can be added to a template; see "Barcode" on page 671. The barcode can be added either using the Barcode toolbar button or through selecting Insert > Barcode on the menu; see "Adding a Barcode" on page 671. Initially the barcode will have the barcode type's default properties.
-
l Second: This mode indicator identifies symbols formatted in accordance with specific industry or application specifications previously agreed with AIM International. You must then set a value for the Application Indicator property. Tilde processing Check this option to process tilde (~) characters in the data as special characters. (See the Java4less Barcodes Guide to learn what the tilde character can be used for.
-
mm. Please do not change the barcode dimensions in the
entry as this will invalidate the barcode. UPC-A, UPC-E, EAN-8, EAN-13 UPC-A, UPC-E, EAN-8 and EAN-13 are a few of the barcode types that can be added to a template. The barcode can be added either using the Barcode toolbar button or through selecting Insert > Barcode on the menu; see "Adding a Barcode" on page 671. Initially the barcode will have the barcode type's default properties.
-
Supplement UPC-A, UPC-E, EAN-13, and EAN-8 may all include an additional barcode to the right of the main barcode. l Type: The supplement type can be 2-digit (originally used to indicate the edition of a magazine or periodical) or 5-digit (used to indicate the suggested retail price for books). In case this option is set to None, and the data includes digits for the 2 or 5 supplement, the supplement data will be skipped and the additional barcode will not be rendered.
-
l l SVG: Vector format. This is usually of higher quality, but may take longer to generate and is not compatible with Email output. PNG: Binary rasterized format. This has a slightly lower quality than SVG but is usually generated faster and will display properly in Email output. Australia Post, Japan Post, KIX, USPS IMb Australia Post, Japan Post, KIX and USPS IMb are some of the types of barcodes that can be added to a template; see "Barcode" on page 671. In PlanetPress Connect versions prior to 2019.
-
l l None: The barcode is rendered based on the module width. Proportional: The barcode is stretched up to where it fits either the width or height of the parent box, whichever requires the less stretching. Color The Color group allows you to choose a different Barcode color (instead of black) and Background color (instead of white), by typing a hexadecimal color value (see for example w3school's color picker).
-
Barcode properties This topic lists the properties of the USPS IMpb barcode type. For the properties of other barcode types, see "Barcode type and properties" on page 673. Color The Color group allows you to choose a different Barcode color (instead of black) and Background color (instead of white), by typing a hexadecimal color value (see for example w3school's color picker). When black is a composite of CMYK or RGB values, it may incur a color click charge on some printers.
-
Tip With the Copy fit feature, text can automatically be scaled to the available space in a Box or Div. See "Copy Fit" on page 802. Positioned Box A Positioned Box is one that can be freely moved around the page and does not depend on the position of other elements. A positioned box is actually a
element that has an absolute position; in other words, it has its CSS property position set to absolute (see also: "Using the CSS position property" on page 805).
-
l offset-y defines the vertical position of the box relative to its container. These attributes can be set in a script. The following script dynamically changes the position of a Positioned Box in a Print context by setting the offset-x and offset-y values. results.attr('offset-x','96'); results.attr('offset-y','96'); The measurements are in pixels (e.g. 96px = 1in). Note that you do not need to set the units. Note Do not set the top or left property of a Positioned Box in a style sheet.
-
Positioning an Inline Box Initially an Inline Box will float to the left. Use the (Float left), (No float) and right) icons on the toolbar to change the position of an Inline Box within the text. l l l (Float The Float leftbutton aligns the Inline Box to the left. The text is positioned to the right of it and is wrapped around the box. The Float rightbutton aligns the Inline Box to the right, with the text wrapped around it to the left.
-
Adding a Div element To add a Div, select Insert > Structural Elements > Div on the menu. For an explanation of the options, see "Inserting an element" on page 668. HTML tag: div, span When you add elements, such as text, images or a table, to the content of a template, you are actually constructing an HTML file. It is possible to edit the source of the HTML file directly in the Designer; see "Editing HTML" on page 666. In HTML, boxes are
elements. Spans are
elements.
-
For a list of known backward compatibility issues see: "Business Graphics: Backward Compatibility Issues introduced in 2018.1" on page 116. Also note that charts based on expanded, custom scripts are never converted. Inserting a business graphic The Connect Designer has wizards for adding three kinds of graphics: Pie Charts, Bar Charts and Line Charts.
-
* If the current element is located inside another element, use the Elements drop-down to select which element is used for the insertion location. The list displays every element in the breadcrumbs, from the current selection point down to the root of the body. Note: HTML has some restrictions as to which types of elements are allowed as children of other elements. For example, a paragraph element is not allowed to have children that are block level elements - like a Div or a Table.
-
to the data-amchart attribute (in a dataProvider property). Connect then passes the value of that attribute to the integrated amCharts library. Rasterizing a business graphic Business graphics are output as SVG images, but not all clients may support that format. Before generating output, you may want to 'rasterize' it. This converts the business graph into a JPG or PNG image. To rasterize a business graphic, right-click it and select Rasterize Options.
-
Note In Pie Charts, only data from the first record in the detail table are used. How to create a Pie Chart that has one slice per detail record is explained in a How-to: Put one slice per detail record in a Pie Chart. 2. For a Bar or Line Chart based on a detail table, you also have to select a Category: one data field (in the detail table) of which the values will appear under the bars or the line; in other words, on the x axis. 3. Next to Values, select data fields with a numerical value.
-
Chart.... See: "Enhancing a charts' design" on the facing page. 6. Use the Move Up and Move Down buttons to change the order of the fields, which is reflected in the chart. The Preview shows what the chart looks like with the current settings, whilst the Data Preview shows which data will be passed to the amCharts library. Preparing a data table By default, a chart that is based on a detail table shows one series ("category") of bars/points per record.
-
When creating a data mapping configuration (see "Data mapping workflow" on page 246), it is recommended to arrange data in a detail table in such a way that it matches this 'one series per record, one bar/point per data field' approach. Occasionally you may find that data in a detail table does not match this approach, and that it would be a better fit if the chart had one series of bars/points for each selected detail data field instead, and one bar/point for each record.
-
Adding and editing properties manually The last tab menu in the Chart Properties dialog, the Source tab, reflects the choices made in the other tabs. More importantly, this tab gives you the possibility to add any amCharts configuration option that is unavailable via the other tab menus. On the Source tab, all settings are given in JSON.
-
The Source tab also lets you change properties that are available in either the Script Wizard or other tabs of the Chart Properties dialog. You could, for example, set the colors of the bars, lines or slices by adding an array of hexadecimal color values, like this: "colors": ["#FF6600", "#FCD202", "#B0DE09", "#0D8ECF"] Note that properties defined on the Source tab override those made in the Script Wizard or on other tabs of the Properties dialog.
-
2. The 'light' theme requires no other settings. For the other themes you will have to manually set the background color of the Div element that holds the chart: A. Switch to the Design mode. B. Right-click the chart area and select Box... from the contextual menu. C. On the Background tab, set the Color to: l #282828 for the 'dark' theme and the 'chalk' theme l #222222 for the 'black' theme 3. Finally, the 'chalk' theme requires adding a remote stylesheet with this URL: 'https://fonts.googleapis.
-
scanning. Camera The Camera element adds a group of buttons to capture or select an image. Once the image is selected via the camera or the device's library (aka "gallery"), it is saved within the Form data. When the form is submitted, the image is sent in a base64-encoded string format. To learn how to add Camera data to a template, see "Adding Camera data to the template" on page 608. The Camera element has a number of options, of which most can be set in the Design view.
-
properties, and then check Allow annotations. Clicking (or rather, touching) the image will bring up the annotation dialog. Annotations can be made in a Marker (semi-transparent) or Pencil (solid) style, in different colors and with different widths. Annotations are submitted in SVG format by a hidden input added to the Camera element. The name of that input is the ID of the Camera element, followed by "-note-data", for example camera1-note-data.
-
How to use the captured or selected image in a template After a user has submitted the form and the data has been extracted, you may want to display the captured or selected image in a Designer template, for example in a letter or on a web page. To do this: 1. Load the data mapping configuration (or at least the data model). 2. Insert a dummy image in the template. 3. Right-click the dummy image and select Dynamic Image. The Text Script Wizard appears. 4.
-
Document ID The Document ID element retrieves the Document ID of the form currently viewed by the app. You could put the Document ID in a hidden input, so that when the form is submitted, the Document ID is submitted as well. A Document ID can be used on the server side to check (in the Connect database) if the data has already been submitted. Fields Table The Fields Table element adds a table with two rows, a Delete button at the end of the first row and an Add button at the end of the second row.
-
Image & Annotation The Image & Annotation element is meant to be used with an image that needs input from the user. When inserting an Image & Annotation element you have to select the image. The user can simply click (or rather, touch) the image to bring up the annotation dialog. Annotations can be made in a Marker (semi-transparent) or Pencil (solid) style, in different colors and with different widths. Annotations are submitted in SVG format by a hidden input.
-
containing box in a template. With previous versions of the app, the format of returned signatures could vary. Time and Formatted Time The Time element and the Formatted Time element display the current time on the device when the form is first opened. When the element is touched, a time selector appears so the user can modify this time. The Formatted Time element displays times in a format that depends on the locale of the device on which the user is viewing the form.
-
Click OK to insert the date or Cancel to close the dialog. Tip If you are looking to add a date that originates from a record set, to a template, see: "Variable Data" on page 846. To insert a date you could use either the drag and drop method or the Text Script Wizard; the latter lets you set the date/time format. Changing the date Once inserted, a date can be modified directly in the template (if it does not update automatically) or through the date script (if it does update automatically).
-
Forms Web templates can contain Forms. Capture OnTheGo templates always contain a Form. Tip To create a Capture OnTheGo template, preferably use a Template Wizard (see "Capture OnTheGo template wizards" on page 612). The Wizard doesn't just add the form, it also adds the necessary Capture OnTheGo form elements (see "COTG Elements" on page 743), style sheets and JavaScript files, and extra pre-made elements. Adding a Form This procedure describes how to add a Form element to an existing Web context. 1.
-
5. Using the the Method drop-down, select whether the form should be sent using the GET or POST method. 6. Using the next drop-down, select the form's Encryption Type (enctype): l l l application/x-www-form-urlencoded: Default. All characters are encoded before they are sent. Spaces are converted to "+" symbols, and special characters are converted to ASCII HEX values. multipart/form-data: No characters are encoded. This value is required when you are using forms that have a file upload control.
-
l l l l l l At cursor position inserts it where the cursor is located in the template. Before element inserts it before the HTML element in which the cursor is currently located. For example if the cursor is within a paragraph, the insertion point will be before the
tag.* After start tag inserts it within the current HTML element, at the beginning, just after the start tag.* Before end tag inserts it within the current HTML element, at the end, just before the end tag.
-
with CSS files" on page 786). l l l An Action: the URL where the form data should be sent. The URL should be a server-side script that can accept form data (a Workflow process that starts with a Server Input task, for example). A Method: this defines whether the form should be sent using the GET or POST method. An Encryption Type (enctype): l l l application/x-www-form-urlencoded: Default. All characters are encoded before they are sent.
-
l l Maximum length: Enter a numerical value for the minimum character length accepted for this field. Equal to: Use the drop-down to select another field that is already added to the same Form. The contents of both fields must match for the data to be validated. This is useful for confirmation fields such as for passwords, email addresses etc.
-
validation. For more information about Forms and Form elements in the Designer, see "Forms" on page 751 and "Using Form elements" on page 591. For more information about elements in Forms, see https://www.w3schools.com/html/html_ forms.asp. Fieldset A fieldset is a group of related elements in a form. The elements don't have to be of the same type.
-
Text area The Text area element is a text field accepting multiple paragraphs. You can set a number of rows when adding the Text Area to the Form, and change it on the Attributes pane. Hidden field A hidden field can contain specific data used by the server-side script. It is not visible to the user. When adding a Hidden Field you can set the value that will be sent on submit. Label A Label element is a text displaying informative text within the form. Labels are non-interactive.
-
You could also create a Radio Button Group by specifying the same submit name for a number of Radio Buttons when adding them to a Form. Radio Button A radio button sends information to the server whether it is selected (true) or not (false). When adding a Radio Button you can set its initial state and its value. The contents of the value property do not appear in the user interface. If a Radio Button is in selected state when the form is submitted, the name of the Radio Button is sent along with its value.
-
A button of the type button doesn't have a standard function. This is mostly used with a JavaScript to activate a script. The button's type can also be changed on the Attributes pane. l There may be multiple submit buttons on a Form. If this is the case, specify a different name and/or value for each of the buttons. Note: When adding a Button to a Form, you can specify a value, but no name. The Button's ID will be copied to the element's name attribute.
-
Adding a hyperlink or mailto link 1. Select text or an image. Note Although it is possible, it is not advisable to add a Hyperlink to other elements, such as a Paragraph or Div. HTML 4 specifies that hyperlinks and mailto-links may only contain inline elements. Block elements, such as a Div, may not appear inside a link. HTML 5 states that the link "may be wrapped around entire paragraphs, lists, tables, and so forth, even entire sections, so long as there is no interactive content within (e.g.
-
l l l Email: enter a valid email address that appears by default in the To: field of the email client. Subject: type a default subject that appears in the Subject: field of the email client. Message: type a message that appears by default in the Message field of the email client. Note that all these can be changed within the email client once the link is clicked. Tip To quickly change the text of a hyperlink, position the cursor on the link and click ~contents in the Breadcrumbs.
-
l PDF l PNG l SVG l TIF/TIFF Base64 encoded images are supported; however, they are added differently: set the src attribute of an element to the base64 code (see below, "HTML tag: img" on the next page). For Email and Web output, PNG is the preferred image format. EPS, PDF, SVG and TIFF images in an Email or Web section are automatically converted to PNG to ensure that they can be seen in the browser or email client. 32-bit BMP files are not supported.
-
select an image to be used as the element's background image. See "Background color and/or image" on page 815 and "Using a PDF file or other image as background" on page 523. Tip Editing PDF files in the Designer is not possible, but when they're used as a section's background, you can add text and other elements, such as a barcode, to them. The quickest way to create a Print template based on a PDF file is to right-click the PDF file in the Windows Explorer and select Enhance with Connect.
-
Note The Connect image cache size is limited to 100MB. This allows most output jobs to run faster. However, if a job requires more than 100MBs of image files, then the Connect image cache size can be increased to cater for such. Please contact OL Support for instructions on how to modify the image memory cache value, if needed. (See also: "Limit of 100MB of image files within a single job" on page 118.
-
Via drag-and-drop The drag-and-drop method is a quick way to import one or more images into a template. 1. Look up the image file or image files on your computer using the Windows Explorer. 2. Select the image (or images, using Shift+click or Ctrl+click) and drag the image file from the Explorer to the Images folder on the Resources pane at the top left. 3. To place an image in the content, drag it from the Images folder on the Resources pane to the content and drop it.
-
Note If a URL doesn't have a file extension, and the option Save with template is not selected, the Select Image dialog automatically adds the filetype parameter with the file extension as its value (for example: ?filetype=pdf (if it is the first parameter) or &filetype=pdf). The filetype, page and nopreview parameters are not sent to the host; they are used internally. Therefore, URLs that rely on one of these parameters cannot be used.
-
Using one file that contains a collection of images (a 'sprite') When a template that contains lots of images is merged with a large record set, the many file requests may slow down the process of output generation. One solution is to combine the images into a single image file (an 'image sprite') and display the part that holds the image. This reduces the number of file requests and can improve the output speed significantly.
-
Just like many other elements, images can be given borders and rounded corners, they can have inner and outer margins and they can be rotated. How to do this is described in general formatting topics, such as "Border" on page 817 and "Spacing" on page 829. All general formatting topics are listed under "Styling and formatting" on page 785. Note It is recommended to resize images outside of the Designer, with image editing software.
-
Note When CSS repeating gradients are displayed in a PDF reader, artifacts, like very thin lines may occur. When this happens, try setting the gradient's position a little bit different. Table Tables serve two different purposes: they are a way to display data in a tabular format, and they are also a way to position elements on a page. In HTML email, Tables are the most reliable way to position text and images; see "Designing an Email template" on page 549.
-
Inserting a Table 1. On the toolbar, click the Insert Table button, or on the menu select Insert > Table > Standard. 2. Enter the Table's desired attributes: l l ID: a unique identifier for the Table. IDs are used to access the Table from scripts and as CSS selectors for style rules. Class: A class identifier for the Table. Classes can be shared between elements and are used to access the Table from scripts and as CSS selectors for style rules.
-
Note l l Tables with an absolute position are only useful in Print sections. Tables on a Master Page have to have an absolute position, unless they are located inside another element with an absolute position. 4. Click Next and select the desired table style. The top left actually applies no styling to the table. The style can be easily changed afterwards; see "Styling a Table" on the facing page. 5. Uncheck the box Allow resizing if the columns should not be resizable in the workspace (in Design mode).
-
Alternatively, right-click the Table and on the shortcut menu, select Row > Insert Above or Insert Below, or select Column > Insert Before or Insert After. Deleting a row or column To delete a row or column, simply right-click the row or column and select Row > Delete or Column > Delete on the shortcut menu. If the deleted row was targeted by a script, you will be asked if you want to delete the script as well. Styling a Table The Insert Table wizard lets you select a style for the table.
-
l Click in the Table and drag the handles to resize it. Press the Shift key while dragging to scale the Table proportionally. This option only works in a Print section, with a Table that has an absolute position and for which resizing is allowed. l l If the position of the Table isn't absolute, right-click the Table and on the shortcut menu, select Convert to absolute.
-
Adding text To add text, simply type in the workspace in the middle. l Press Enter to insert a new paragraph. l Press Shift+Enter to insert a line break. Alternatively, use the Insert Lorem Ipsum toolbar button to insert dummy text, or copy-paste text into the template. Select Paste as Plain Text from the Edit menu or the contextual menu to insert the text without any HTML styles or formatting.
-
HTML element: p, h, li and others When adding elements, such as text, images or a table, to the content of a template, you are actually constructing an HTML file, which you can see and edit on the Source tab (see also: "Editing HTML" on page 666). In HTML, text can be contained in many different elements: paragraphs, span elements, line items and table cells, for example. The HTML tag of a paragraph is
. The paragraph should be followed by a closing tag:
.
-
l Handlebars templates can contain HTML and Handlebars expressions; see "Handlebars templates" on page 781. The information in this topic applies to all or at least two types of snippets. Note Regarding styling: when a snippet is added to different sections or contexts, it is displayed according to the section's or context's style sheet. This means that the same content can look different depending on the styles applied to the section or context, without changing the content.
-
Remote snippets A remote snippet is either an HTML or JSON file that is not located within your template file but is hosted on a Content Management System or other external location. To add a remote snippet: 1. Right-click the Snippets folder on the Resources pane, and click New Snippet > Remote HTML file or Remote JSON file. 2. Enter a name for the file as it appears in the Snippets folder. This name is shown in the Snippets folder with the .rhtml file extension for HTML, or .rjson for a JSON file. 3.
-
Tip It is also possible to create a new HTML snippet from an existing piece of content in the template; see "Using content to create an HTML snippet" on the next page. Adding a snippet to a section Each type of snippets is used differently; see "Adding an HTML snippet to a section" on the next page, "Using a JSON snippet" on page 781 and "Using Handlebars templates: examples" on page 784. Editing a snippet To edit a snippet, open the snippet file by double-clicking it on the Resources pane.
-
Snippets folder on the Resources pane, but their file name ends in .html. This topic contains information that only applies to HTML snippets. If you want to know how to add an existing (remote) snippet to the resources, or how to create an empty HTML snippet, please see "Snippets" on page 775. Tip It is possible to open and edit any external HTML file in the Designer: select File > Open, select All files (*.*) as the file type and then select an HTML file.
-
Editing shared content By default, an HTML snippet that is being used as shared content can also be modified in a section where it is used. That way you actually adjust its source. The snippet will be changed at all locations where it is used. The option to modify shared content snippets from within a section can be turned off: l l In the menu, select View > Shared Content Editing to enable or disable editing of all shared content.
-
JSON snippets JSON snippets are snippets that contain JSON data instead of text. Just like other types of snippets, JSON snippets are stored in the Snippets folder on the Resources pane, but their file name ends in .json. This topic contains information that only applies to JSON snippets. If you want to know how to add an existing (remote) snippet to the resources, or how to create an empty JSON snippet, please see "Snippets" on page 775.
-
Handlebars is the name of a JavaScript library that implements a templating language (see https://handlebarsjs.com/). It uses a template and an input object to generate output. Handlebars templates look like regular text with embedded Handlebars expressions. A handlebars expression is a {{, some contents, followed by a }}. For example:
Hello {{firstname}} {{lastname}}!
When the template is rendered, these expressions are replaced with values from an input object.
-
Using a Handlebars template in a section Although Handlebars templates contain HTML text, they cannot be inserted into the content of a section directly. The following steps need to be taken in order to replace Handlebars expressions with values and then add the content of a Handlebars template to a section. Render the Handlebars template First the template needs to be rendered, i.e. converted into HTML, replacing the expressions with values.
-
1. Compile the Handlebars template into a function Handlebars templates need to be compiled first. When a Handlebars template is compiled, it is actually compiled into a JavaScript function. 2. Call the function to replace expressions with data The second step is to call the resulting function, passing in some data. The function will replace the expressions with values from the data and will then return HTML. Instead of calling Handlebars.render() you could call Handlebars.
-
This is an example: let html = '' let policydata = record.tables.Policy for (var i=0; i < policydata.length; i++) { let templateName = 'snippets/' + policydata[i].fields ['snippetName'] + '.hbs' html += Handlebars.render( templateName, policydata[i] ) } results.replaceWith( html ); Styling and formatting In the Designer you have everything at hand to make your templates look good: colors, fonts and all the tools to position, align and embellish elements in your designs.
-
time and again, when the company's layout preferences change. See "Styling templates with CSS files" below. Layout properties Colors and fonts make an important contribution to the look and feel of your template. See "Colors" on page 819 and "Fonts" on page 823. Text and paragraphs have a number of formatting options that are not available for other elements: font styles and line height, for example. See "Styling text and paragraphs" on page 799.
-
Why use CSS files The basic idea behind CSS is to separate the structure and contents of a (HTML) document as much as possible from the presentation of that document. Cascading Style Sheets were originally designed for use with web pages, or HTML files. Since every template in the Designer is constructed in HTML, CSS files can also be used in the Designer. Instead of setting the font size, line height, color etc.
-
What you can't do with CSS In Connect, it depends on the output channel what can and cannot be done with CSS. CSS can only be used to its full potential with HTML output. Animation and transition features won't work in Print output, obviously. Included Cascading Style Sheets When you create a template, a number of style sheets is automatically included: l l l One style sheet that applies to all document types: context_all_styles.css. One or more style sheets specific to the context (Print, Email, Web).
-
Note The order in which style sheets are executed, can affect the actual output. This sequence can be set per section; see "Applying a style sheet to a section" on page 502. Tip l l To export a CSS file from your template, drag or copy/paste it out of the Stylesheets folder to a folder on the local hard drive. It is possible to open and edit any CSS file in the Designer: select File > Open, select All files (*.*) as the file type and then select a CSS file.
-
example: a folder location on a corporate website, hosted by a CDN (Content Delivery Network) or shared via a Workflow process. Tip After adding the remote file, you may right-click it and select Download Resource. This allows you to maintain a central file, from which you can quickly download a copy to your template without having to copy & paste. Note that a local copy of a remote resource is a snapshot; it is not automatically kept in sync with its remote content.
-
Styling your templates with CSS files Note Email clients do not read CSS files and some even remove a