Knowledge Base

View Categories

Custom Questions and On-the-Fly Questions

Custom Questions: Tailored Data Collection Made Simple

Unlock the full potential of collecting data during barcode scanning with Custom Questions and On-the-Fly Questions. These features are designed to provide developers with unparalleled flexibility in tailoring workflows and capturing critical information. Whether you’re creating custom scripts or managing responses in real-time, this guide will help you understand and implement these features seamlessly.

Custom Questions empower developers to design tailored prompts using HTML and JavaScript. These questions can collect, validate, and store data as part of an official scan record, offering flexibility to suit your workflow needs.

Why use Custom Questions?

Context-Based Flexibility

Create dynamic question flows using variables such as:
__SCAN_VALUE__
__SCAN_RESPONSE__
__SCAN_STATUS__
__USERNAME__

Custom Formatting
Format inputs like dates, ZIP codes, or phone numbers. You can validate user responses to ensure they meet expected criteria.

Multiple Data Points
Ask single or multiple questions in one session, with answers saved directly into the scan record.

How to Add Custom Questions?

Custom Questions can be added via the API or the web UI under the “Questions” tab while setting up a service.

Options Available:

  • URL: The most flexible method, ideal for managing data with your server.
  • HTML: Best for offline data collection or when server usage is not required.

Examples of Custom Questions in Action

  1. Auto-Insert Current Date
    • Automatically include the device’s date. This timestamp updates dynamically during edits or session use.
  2. Dropdown Menu for Date Selection
    • Pre-fill dates with the current timestamp but allow users to edit for flexibility and accuracy.
  3. Dependent Questions
    • Show follow-up questions based on specific answers. Multiple answers can be tied to a single scan record.
  4. Conditional Fields
    • Enable specific fields based on selected answers. For instance, selecting “Other – Enter Answer” opens a text field.
  5. Capture Username Property
    • Store the app user’s username as part of the scan record.

Take a look here at our API docs that show basic instructions for setting up custom questions for barcode scanning. Also, review this PDF file that has code examples for the __SCAN_VALUE__ and __SCAN_RESPONSE__ variables.

Notes:

  • Unsupported Features: Photo Collect and Signature Capture are not supported within Custom Questions. Use On-the-Fly Questions for these needs.
  • Custom Scan Response Handling: Adjust the scan response handling to show changes in real-time. Contact support to enable showScanResponseChanges=true or configure this property via API.

Custom ‘On-the-Fly’ Questions: Real-Time, Dynamic Data Collection

How On-the-Fly Questions Work

On-the-Fly Questions are a dynamic option for creating context-sensitive prompts during barcode scanning. Unlike Custom Questions, these are only displayed based on specific triggers defined by your server.

How On-the-Fly Questions Work

  1. Real-Time Scan Postback
    • Each scan record is posted to your server immediately after scanning.
  2. Server Processing
    • Your server processes the barcode value and any previously submitted answers.
  3. Dynamic Question Presentation
    • Based on the processed data, your server can:
      • Present additional questions.
      • Skip further questions if no additional input is required.
  4. Iterative Questioning
    • Once the user submits their answers, your server can:
      • Present further questions.
      • Approve the scan and allow the user to move to the next record.

On-the-Fly Questions: Refer to the documentation to use Postback URL for On-the-Fly Questions.

Key Takeaways

  • Custom Questions are ideal for predefined, structured data collection and validation.
  • On-the-Fly Questions enable dynamic, server-driven prompts tailored to each scan’s context.
  • Both features integrate seamlessly into your workflow, improving data accuracy and usability.

By leveraging these powerful tools, you can create a seamless, customized experience for app users while capturing all the data you need for your operations.