The Build Tab is the heart of form building, as you choose the fields that users will respond to. Learn more about forms in the Online Forms Overview article.
In This Article
When you click the Build tab, the Build Tool box will appear on the screen. Use this box to quickly add fields or triggers, or change other Form Properties.
- If the box is in your way, click near its title and drag the box to a different location.
- To make the box reappear, click on Form Properties (top right) or on any of your form fields and the Build Tool box will appear with the properties of that field.
- If the form doesn't have any fields yet, select a section type at the bottom of the form screen, or click Form Properties to bring up the options to click 'Add Field'.
- To make the box disappear, click the small red X top right to close it.
Add Field
The starting point for building a form, survey, or test is to begin adding fields.
When you click Add Field in the Build Tool box you'll see a list of all the fields available for forms. Each of these fields is described below. As you click on a field name to add it to your form, you'll see the new field immediately display on your screen behind the Build Tool box.
When you add a field you'll need to give it a Label. If you change your mind about adding that field, you can immediately click Remove Field in the Build Tool box.
More properties provides you with additional options on the field you are adding. Click this option from the build tool as shown on the previous image to access additional options:
- Orientation - display field label above as shown with 'comments' in the below screenshot
- Required - The form can't be submitted without this field being filled in
- Validation - This option is described below
- Size - reduce the size of your field on the form
- Instructions - Text in this box appears below the input option of the form
- Private - Hides this field for Admins and specific users
- Permissions for this are set in the 'Security' tab
You can manage these additional properties at a later time.
Form Field Types
The following list provides a brief description of the different form fields and their unique options.
Content Field
Add descriptive text or html markup to your form. These are additional words on the page rather than a field users would complete. For example, if you're building a test form and want to provide information, videos, or links to references.
Text Box, Message Box
Text boxes contain a single line of text.
Message boxes contain one or more lines of text. As well, message boxes can be displayed as an HTML editor box. HTML editor boxes offer users a rich text editing toolbar that provides more options, including submitting video uploads, flash videos, images, and much more.
Both text boxes and message box have no character limitation.
When modifying an existing text box or message box, clicking more properties in the Build Tool box will reveal a Validation field. Validation will allow you to enforce minimum and maximum limit on the number of characters that a submitting user can enter. Additionally, you can define your own regular expression, or regex, which will allow you to enforce a set of rules on the accepted value types; learn more about regular expressions. The validation message contains the text that users will see when they enter a field value that fails the validation you’ve implemented. Test value allows you to test the validation of your field by entering a value and clicking the test button.
All Staff
The all staff field generates a dropdown list of all employees on your intranet. Allowing the submitting user to select an individual, rather than typing in their name. Entering the first letter of an employees name will take you to that letter on the alphabetically arranged list.
File Upload
Supports file attachments to responses. (This field is not available for tests.)
Date Field
Collect date and time information with this field. Type gives the option of collecting either date or time, date only, or time only.
Clicking more properties reveals an optional Default Now checkbox. Selecting this option will automatically populate the date field with the current date.
Link Field
A text box with built-in URL validation. (This field is not available for tests.)
Email Field
A text box with built-in email validation. (This field is not available for tests.)
Number Field
Number Format allows you to define the type of formatting that you’d like use for the numbers provided by your users. Format options include currency, decimal, or whole number. (This field is not available for tests.)
User Data
Data for the submitting user can be automatically included in to the form response. Click the small black arrow beside Field to see all of the Person, Login, and Employee fields which can be included in a form. Note that this data can only display for users who are logged in when accessing the form, so it will not work for anonymous users.
Formula Field
Output fields whose value is based on other fields. Formula fields can be added within a spreadsheet to add, subtract, divide, or multiply content added to the following fields: Drop down, checkboxes, radio buttons, number, and mileage. Formula fields can be added to sections to calculate the sum, average, field count, minimum value, or maximum value of these fields contained within the spreadsheet. (This field is not available for tests.)
SQL query
The SQL query field pulls information from an application database that is presented to users in a drop-down list which they can select from. (This field is not available for tests.)
After you've added this field, enter your query in the format select [your select text column] as OPTIONVALUE from [table name], and click the gear shown in the image below to execute the query.
Note: You can also pull information from another database if needed by adding the database to a new Datasource in Lucee, naming it appropriately, then using that datasource name on the more properties options of the SQL Query field.
SQL query examples:
- To show user first and last names in your drop down
- SELECT p.FirstName + ' ' + p.LastName
FROM Person p INNER JOIN Employee e ON p.PersonID = e.PersonID
ORDER BY p.FirstName, p.LastName
- SELECT p.FirstName + ' ' + p.LastName
- To show department in your drop down
- select a.Department as OPTIONVALUE from EmployeeDepartment a Inner Join Employee b on a.DepartmentID = b.DepartmentID Inner Join UserProfile c on b.PersonID = c.personID where c.UserID = *UserIdentification*
- To show a list of items from a specific folder within an AppBuilder app
- SELECT Title FROM AppBuilderData<MenuID> WHERE CategoryID = <CategoryID> ORDER by Title
- Replace MenuID with the MenuID or AppID shown in the URL when in the AppBuilder app
- Replace CategoryID with the CategoryID shown in the URL when in the specific folder of the AppBuilder app
As this field requires knowledge of SQL query strings, it is not supported, however, if you would like a copy of our data dictionary to create your own query, please request through support@intranetconnections.com .
Connecting to an external database:
If you're looking to connect to an external database, please review the following video:
Required steps:
- Create a Datasource in Lucee
- The datasource name cannot be named 'sqlfunctions' as used by your intranet database
- Edit Online Form
- Click Build tab
- Add/click on the SQL Query field
- Click More Properties
- Add the datasource name for your external database into the provided datasource field:
Mileage Field
The Mileage field allows users to select two points on a map and have the software perform an automatic calculation of the driving distance between the selected points. Clicking more properties will show a Unit System dropdown with the choice of calculating distance in either Imperial (miles) or Metric (kilometres). Selecting the checkbox for Show Locations will display the locations selected using the map feature, inline, on the form response. (This field is not available for tests.)
Adjusting Mapping API Settings:
In addition to the mapping settings within the fields of a form in the Online Forms app, there are Mapping options in the Admin area of your site. Navigate as an admin to Admin > Setup tab > Mapping API.
- Locale - Select your country from this list
- Unit System - Select from Metric or Imperial (you will need to adjust this in the form mileage field as well)
- Default Location - This starting location is used when users click on the icon to add their start/end addresses for mileage calculations.
- To set:
- Zoom out using either your mouse wheel or the - icon on the map shown in the image above.
- Next, locate your office location.
- Right-click on the map to set the starting pin.
- To set:
Save any changes made on this screen.
Videos: Did You Know...
Working with Fields
After you've added a field, the Build Tool box will give the option to Copy Field. This can be helpful if you've built a complicated field and will now use a similar one. Copy the field so you don't have to redo all of your work.
Fields can be moved to a different location or section in any form, survey, or tool. Mouse over the field you want to move, and drag and drop it to a new location.
If you want to edit a field, click on it and the Build Tool box will appear with the field properties. You can also delete a field in this box.
Fields Sharing a Row
When fields are created, they're automatically slotted in underneath each other horizontally, but they can be moved to share a row (maximum two per row). To do this:
- On the upper row, click the small arrow on the right side. This will make the field smaller so it takes up half the row.
- On the lower row, click the small arrow on the right side. This will make the field smaller and move it up beside the first field. You now have two fields sharing a row.
Deleting Fields
When you're initially building a form, removing a field can happen often. Since you're still in the Draft stage, removing a field is as simple as clicking Remove Field in the Build Tool box.
When updating a live form, you run the risk of data integrity. It's recommended to not remove any fields from a live form as previous submissions will be impactedHowever, removing a field once responses have been received is a bit more complicated, as you not only remove that field, but all of the associated responses. You will be presented with a confirmation message as shown below, asking if you're sure you want to continue.
Private Fields
Sometimes all available form data (e.g. salary) shouldn't be viewed by everyone who has access to a form or survey. In this case, you can designate a field or fields as private (note that this is not an option for Tests):
- Click the field to edit it. The Build Tool box will appear.
- Click more properties.
- Click the box for Private. If the box doesn't appear it's not an available option for that field or form.
- Click the Security tab to specify who should access the private fields.
Watch this video to learn more about setting up private fields:
Required Fields
Sometimes there are fields that must be entered for the form results to be useful. In this case, you can designate a field or fields as required:
- Click the field to edit it. The Build Tool box will appear.
- Click more properties.
- Click the box for Required (if the box doesn't appear it's not an available option for that field or form); a red asterisk appears, which will also be visible to users.
- Enter a required message this message will be displayed upon form submission if the field is not filled in.
Sections
Sections are used to group fields together on a form, survey, or test, to make content easier for users to understand (e.g. Personal Information, Client Requirements). A form can have many sections containing different groups of fields.
To add a section, click the link which is shown on the bottom left side of a form (1), as in the image below; this will open the Build Tool box with the properties of the section. Name the section heading (2), and go ahead and add some fields to your new section (3). You can also click and drag existing fields into a new or existing section.
If you no longer want a Section, to delete it either click the red circle to the right of the section, or click Remove Section (5) within the Build Tool. Note that this will also remove all of the fields, or questions, within that Section and any associated responses.
Field Triggers
Field triggers let you add conditional logic to a form, survey, or test so that form fields or sections will show to users only if a specific value is entered. For example, I could ask users "Do you have a pet?", and only if they answer "yes" would a question about types of pets appear.
To add a trigger:
- First create the fields that will be used in the trigger (i.e. the initial question and the resulting question or section), and click Save Changes. If the fields to be used in the trigger haven't been saved, they won't show as available trigger options.
- Click on the field or section which is conditional (i.e. which you want to be shown only if a condition is met). The Build Tool box appears.
- Click Add Trigger. The Build Tool box now shows Trigger Properties rather than Field Properties. You can also click Remove Trigger here if you change your mind.
Configuring Field Triggers
You now have a series of properties to set up for this trigger, as shown in the image below:
- Name - you can add a name that describes the trigger's purpose.
- Color - a default color is suggested (this isn't visible to users). You can use this to visually separate your triggers. Click on the color, then click on the wheel to select a new color.
- Show - if you started by clicking on a field or section, its name will be here. If not, browse for the name of what you want to be shown only if a condition is met.
- Only If - choose the dependent trigger field here.
- Value - set the value for the trigger here, using mathematical signs such as = equal to, or < less than. If the trigger is dependent on a text-based field, only = can be used.
In the example below, Trigger 1, Type of pet? will show only if the response to Do you have a pet? is equal to yes.
Watch a video of the setup of the form trigger process:
Edit Triggers
When you close the Build Tool box, you'll have a new colored box (1) near the top of your Build tab, with the name of the trigger. The trigger field (2) has a matching colored box, and the conditional field or section has a dotted line (3) in the same color.
To edit a trigger, click on its name and the Build Tool box will appear, with the same properties as shown above. You can also click Remove Trigger to eliminate the trigger without affecting any fields or sections.
Form Properties
Clicking Form Properties near the top of your form shows layout options, described below. As you change a property, it's immediately changed on your form behind the box.
- Width - the width of your form. Use either percentage or numbers.
- Section Spacing - controls the amount of white space between form sections.
- Label Width - the width of the labels for each form field.
- Field Padding - the amount of space around the fields and labels in your form.
Form Custom Code and Form Instructions
If you have specific instructions for users, add it as either custom code or Survey Instructions. Click in the {Survey Instructions} field and add your information using the rich text editor.
Before moving to any other field, click the small blue floppy disk icon, not the arrow, on the lower right to save your instructions.
Change Submit Button Text
Every form, survey, or test includes submit and reset (or clear survey) buttons, lower right on the Build tab.
Customize the names of these buttons by clicking on the button you want to rename, typing your new name, and clicking the small blue floppy disk Save icon.
Related Links