Blog Post

Cleaner Data Templates, New Checkbox and Comments Support

Written by Jamie
January 21, 2015
forms2 Professional business reports and documents - Customised using Data Templates


Stay in the loop:

Beforehand, if you needed to display a checkbox in Microsoft Word or Excel data templates you had to use a fairly complex formulas to produce a simple Unicode character for the ticked or un-ticked box. Similarly, when you’ve needed to use long formulae to achieve a required output, the syntax for this often resulted in word wrapping and distortion of your template’s layout, making it more difficult to style.

We’ve just added support for placeholders in comments, plus a new CBOX() function – this now makes it so easy to use advanced display outputs in your Document Templates.

Improved Check Box Support

Previously, the way to display a check box in your template was to include a function such as:

{{(IF(SELECTED({{myfield}}, 'Oranges'), 'u2611', 'u2612'))}}

This leveraged our Unicode support by outputting either a ☑ (Unicode character 2611) or a ☒ (Unicode 2612).

We’ve decided to include this functionality into the formula engine using our new CBOX() function. From today, you can instead use:

{{(CBOX({{myfield}}, 'Oranges'))}}

Isn’t it much tidier 😉

In addition, you were previously required to format checkbox syntaxes with Segoe UI Symbol font in order to get accurate PDF outputs. Not any more! If you use a CBOX function in your template, our template engine automatically applies Segoe UI Symbol to the placeholder area. This means your template will always display checkboxes correctly. And yes – multiple choice answers are supported by the CBOX functions 🙂

Placeholders & Formulae in Word/Excel Comments

And that’s not all – we’ve also added support for inserting placeholder and formula syntax as MS Word/Excel comments.

How is this useful? Frequently, when building a template your formula or placeholder syntax becomes too long to fit in the designated area of the template. The result is ugly word wrapping and it becomes difficult to visualise how the template layout will look because of the distortion caused by the placeholder text.

Of course, the actual generated result still comes out absolutely fine, but we wanted to make it as easy as possible for you to design your templates without having to constantly generate test outputs to see if template formatting looks good.

We needed a way to “annotate” the placeholder/formula syntax onto specified text in the template. Comments were the natural choice (found under the Review tab in Word & Excel), since they hover near the body content without messing up the layout.

Our template generation engine ignored comments previously, but now it proactively scans for these and will replace text linked to a comment with the placeholder/formula syntax extracted from the comment itself.

For more information, see the new CBOX documentation and Word/Excel Comments article on our support site.

Related Posts

Why You Should Digitise Inspections Using Data Capture Apps

Construction Mobile Apps & Forms

Why You Should Digitise Inspections Using Data Capture Apps

March 31, 2024

Benefits of Data Capture Apps & Digitising Field Data Capture blog banner

Form Builder

Benefits of Data Capture Apps & Digitising Field Data Capture

March 31, 2024