Logo Text Blaze

  • Docs
  • Community
  • Documentation

    Loading...

    Community Forums

    Loading...
Add to Chrome –  It's Free! Go to Dashboard ›
Commands

{error}

Summary: Show an error message in a snippet. Use it to validate user input and block snippet insertion.
Sample Usage
Count: {formtext: name=count; default=0} (count must be greater than 0)

{if: catch(count <= 0, yes)}{error: The count is not greater than 0!; block=yes}{endif}
_

Quick Overview Video

Settings


Setting NameTypeDescription
PositionaltextThe error message to show to the user.
blockyes/noIf yes, blocks insertion while the error is shown.
General Command Settings
trimyes/no/left/rightIf yes whitespace is removed before and after the command. If left, only whitespace to the left is removed. If right, only whitespace to the right is removed.

The error command can be used for form validation and for preventing a snippet from being inserted until certain conditions are met.

The error command is best used in combination with the {if} command to conditionally show an error and block snippet insertion.

The block setting

If the block setting is no the message that you used in the first positional setting will be inserted into your snippet.

Notice how the error text is inserted into the snippet itself inside of the [Error - ] text.

If block is yes, the message will be displayed (not inserted) and the snippet user will not be able to insert the snippet until the error is resolved.

Text Blaze will not allow you to insert the snippet by showing an alert.

Error checking your team's snippets

A good use case for the error command is when you're sharing snippets with your team. It will ensure that everyone using the snippet is entering the right information and validating it correctly before the final insertion.

  • Guides
    • Quick Start
    • Sharing Snippet Folders
    • Dynamic Commands
    • Date and Time
    • Autopilot
    • Forms
    • Tidying Whitespace
    • Lists
    • Teams and Organizations
  • Tutorial Videos
  • Showcase
  • Frequently Asked Questions
  • Formula Reference
  • Dynamic Commands
    • Using Dynamic Commands
    • {=} (Formula Command)
    • {click}
    • {clipboard}
    • {cursor}
    • {error}
    • {formdate}
    • {formmenu}
    • {formparagraph}
    • {formtext}
    • {formtoggle}
    • {if}
    • {import}
    • {key}
    • {link}
    • {note}
    • {repeat}
    • {site}
    • {snippet}
    • {time}
    • {user}
    • {wait}
  • Connected Snippets
    • Connected Snippets Overview
    • {image}
    • {urlload}
    • {urlsend}
    • {dbselect}
    • {dbinsert}
    • {dbupdate}
    • {dbdelete}
  • Command Packs
    • Capitalize
    • Gmail
    • LinkedIn
    • Randomize

About

Plans and Pricing
Sharing Snippets
Text Blaze for Business
Forms
Autopilot
Dynamic Commands
Command Packs

Support

Get Started with Text Blaze
Contact Us
Documentation
Community Forum
Blog

Solution for

Teams
Customer Support
Recruiters
Education
Healthcare
Sales
Property Managers

Other

Privacy Policy
Terms of Service
Open Source Licenses
Affiliate
© 2023 Blaze Today Inc