Supported Question and Data Types for Dispatching

 

Data Types Supported for Dispatch

There are a number of details to keep in mind when planning and using ProntoForms dispatch functionality.  These details apply to web portal single dispatching, web portal-based CSV dispatching, API-based dispatching, and dispatching with the Dispatch Data Destination.  

It is up to the dispatcher to ensure that all pre-filled answers will work with the constraints defined on the form.  If there are problems with the dispatched data (for example, a name is dispatched to a question that requires a phone number), the dispatch will be rejected with an error message. 

For details on how to dispatch into sections via the API, please look at this helpfile: API Dispatching for Repeatable Sections

 

The following data types are supported for dispatch:

API Dispatch Dispatch Destination Web Portal Dispatch Bulk CSV Web Portal Dispatch
  • Date/Time
  • Decimal
  • Time Duration (milliseconds)
  • Email
  • Text
  • Integer
  • Monetary Value
  • Phone Number
  • Time
  • URLs
  • Yes/No
  • Image*
  • Signature*
  • Geo Location **
  • Date/Time
  • Decimal
  • Duration (milliseconds)
  • Email
  • Text
  • Integer
  • Monetary Value
  • Phone Number
  • Time
  • URLs
  • Yes/No
  • Image*
  • Signature*
  • Geo Location **
  • Date/Time
  • Decimal
  • Email
  • Text
  • Integer
  • Monetary Value
  • Phone Number
  • Time
  • URLs
  • Yes/No
  • Image
  • Signature
  • Geo Location**
  • Date/Time
  • Decimal
  • Duration (milliseconds)
  • Email
  • Text
  • Integer
  • Monetary Value
  • Phone Number
  • Time
  • URLs
  • Yes/No
  • Image*
  • Signature*
  • Geo Location **

 

[ top ]

 

Control Types Supported for Dispatch

The following question control types are supported for dispatch:

API Dispatch Dispatch Destination Web Portal Dispatch Bulk CSV Web Portal Dispatch
  • Checkbox
  • Date Picker
  • Time Picker
  • Duration Picker
  • Textbox (Small and Large)
  • Dropdown
  • Multiselect
  • Radiobutton
  • Button Group
  • Stepper
  • Camera
  • Sketch Pad
  • Signature
  • Geo Control*
  • Checkbox
  • Date Picker
  • Time Picker
  • Duration Picker
  • Textbox (Small and Large)
  • Dropdown
  • Multiselect
  • Radiobutton
  • Button Group
  • Stepper
  • Camera
  • Sketch Pad
  • Signature
  • Geo Control*
  • Checkbox
  • Date Picker
  • Time Picker
  • Textbox (Small and Large)
  • Dropdown
  • Multiselect
  • Radiobutton
  • Stepper
  • Camera
  • Sketch Pad
  • Signature
  • Geo Control*
  • Checkbox
  • Date Picker
  • Time Picker
  • Duration Picker
  • Textbox (Small and Large)
  • Dropdown
  • Multiselect
  • Radiobutton
  • Button Group
  • Stepper
  • Camera
  • Sketch Pad
  • Signature
  • Geo Control*

 

[ top ]

 

Unsupported Types

The following types are currently not supported for dispatch:

API Dispatch Dispatch Destination Web Portal Dispatch Bulk CSV Web Portal Dispatch
  • Barcode
  • Digit extractions
  • Calculation
  • Concatenation
  • Geostamp
  • Time/Date Stamp
  • Audio
  • File Upload
  • Information
  • Time-Based Math
  • Credit Card Transaction
  • Slider
  • Barcode
  • Digit extractions
  • Calculation
  • Concatenation
  • Geostamp
  • Time/Date Stamp
  • Audio
  • File Upload
  • Information
  • Time-Based Math
  • Credit Card Transaction
  • Slider
  • Barcode
  • Digit extractions
  • Calculation
  • Concatenation
  • Geostamp
  • Audio
  • File Upload
  • Information
  • Date/Time Stamp
  • Button Group
  • Slider
  • Time Duration
  • Time-Based Math
  • Credit Card Transaction
  • Slider
  • Barcode
  • Digit Extraction
  • Calculation
  • Concatenation
  • Geostamp
  • Audio
  • File Upload
  • Information
  • Time-Based Math
  • Credit Card Transaction
  • Slider

 

[ top ]

  

Multiple Answers (for Bulk CSV Dispatch)

Some controls allow multiple answers to be selected.  To specify multiple answers in a CSV dispatch file, place each answer on a new line.

"Red
Blue
Green" 

In Excel, you can enter a new line within a cell by holding down the ALT key while hitting <ENTER>.

[ top ]

 

Answer Value Containing a Line Break (Bulk CSV Dispatch)

If you want a line break in your single-answer data, the final character of the line must be a forward slash character ('/').  The '/' character will be removed from the value when it is processed by the server.  For example:

"This is/
a two-line input in a CSV"

[ top ]

 

Specifying Multiple Answers in XML (API Dispatching)

Multiple values can be dispatched by defining multiple answer XML nodes. The following answer specifies multiple answers for a question labelled "email."

<answer label="email">a@b.com</answer> 
<answer label="email">b@c.com</answer>

[ top ]

 

Date and Time Formats

The date and time formats used are based on ISO standards.  Values must be specified in Coordinated Universal Time (UTC).

Time Stamp (Date + Time)
Format:     yyyy-MM-ddTHH:mm:ssZ
Example:  2012-01-31T23:59:59Z 

Date Only
Format:     yyyy-MM-dd
Example:  2012-01-31

Time Only
Format:     HH:mm:ss
Example:  23:59:59 

Duration

Format: HH:mm:ss or milliseconds 

Example: 1:30:15 or 5400000

[ top ]

 

Attachment Format

Images can be dispatched to Camera, Sketch Pad, and Signature control types.  Note that the Photo Quality settings on the mobile device (and in form settings) affect dispatched images; images will be compressed or resized as necessary to match these settings.

*When dispatching images (including signature images), images must be Base64 encoded.  Base64 encoding is typically done programmatically, but can also be done with an online tool like http://www.base64-image.de/.  Images must be formatted as image/jpg(or png)|<base64 string here>.  When using the Dispatch Destination, it is possible to select "Automatically dispatch to questions with matching label", which will take data from the dispatching form and automatically route it to fields in the Target Form with corresponding labels.

When using the Dispatch Destination, the Data Expression field is limited to 4000 characters, which is not enough to accommodate most Base64 strings.  Consequently, static image dispatching is not recommended under most circumstances. For more information on dispatching images via the Dispatch Destination, please read: Dispatch Destination.

CSV (Bulk Dispatching)

image/jpg|iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsIAAA7CARUoSoAAAAAQSURBVBhXY/gPBEwMDAwMAB32A/9omztwAAAAAElFTkSuQmCC

 

XML (Through the API)

<answer label="Image 1">
<contentType>image/png</contentType>
<bytes>iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsIAAA7CARUoSoAAAAAQSURBVBhXY/gPBEwMDAwMAB32A/9omztwAAAAAElFTkSuQmCC</bytes>
<filename>My_Image.png</filename>
</answer>
 

JSON (Through the API)

 {
"label": "Image 1",
"data": {
"contentType": "image/png",
"bytes": "image/png|iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsIAAA7CARUoSoAAAAAQSURBVBhXY/gPBEwMDAwMAB32A/9omztwAAAAAElFTkSuQmCC",
"filename": "My_Image.png"
}
}

[ top ]

 

Other Data Formats

Text Formats

For question types that have specific format requirements (email, phone number, url), dispatched answer values must be properly formatted.  Basic text questions have no formatting requirements.

Numbers

Number inputs will only accept valid numerical input. Integer data questions must not have decimal places.

Monetary Value Format

Monetary value data should be provided as a simple decimal. No currency symbol or currency type should be added.

Yes/No

The yes/no answer can be set by using "yes" or "no" as the input string.

Geolocation Format

Geolocation data requires specific formatting, uses latitude and longitude coordinates, and has optional fields for further data in the API Dispatch, Dispatch Destination, and Bulk CSV Web Portal Dispatch. In the Web Portal single dispatch, you can simply start typing the address.

API Dispatch

<answer label="geo">
<latitude>123.456</latitude>
<longitude>987.654</longitude>
</answer> 

Dispatch Destination

Where "geo" is replaced by the appropriate question label.

Bulk CSV Web Portal Dispatch

::latitude,123
longitude,456
altitude,789 (optional)
address,123 fake street (optional)
accuracy,100 (optional)

[ top ]

Was this article helpful?
1 out of 1 found this helpful
Have more questions? Submit a request

Comments