Surveys are for the most part about questions, but often you need to provide some context before users can actually give you a good answer. And that is where notes come into play.
Notes allow you to insert text and images in between questions in your Survey123 smart form
Here are the main three reasons why you may want to use notes in your form:
The use of notes is supported in both the Survey123’s web designer as well as Survey123 Connect. The easiest way to create a note is to use web designer, where you can easily format your text using custom font sizes, colors, bullets for your paragraphs and even embedded images and links. You can also control the alignment of your text in the notes: centered, right aligned and left aligned.
Here is how you can add notes to your survey in Web Designer:
In XLSForms, notes are modeled as a note type of question. The most important rule when using notes is that they do not require any value in the name column of your XLSForm. That is right: unlike other types of questions in XLSForms, the name column is not mandatory. In fact, it is typically better that you leave it empty.
The reason for this is simple: When you publish a survey with Survey123 Connect, the values in the name column of the survey worksheet define the attribute columns in the feature layer where we will persist your data. Since notes do not expect any user input, there is no need to give them a name.
Other than the above, notes behave like most other XLSform questions:
type | name | label |
note | <center><a href="tel:9091234567">Call Water Department</a></center></p> |
type | name | label | media::audio |
note | Play this audio before counting <i>Gubernatrix cristata</i> calls | gcristata.mp3 |
type | name | label | relevant | calculation |
geopoint | location | Location | ||
calculate | speed | Speed | pulldata("@geopoint", ${location}, "speed") | |
note | Do not move while fixing location! | 0.2 < ${speed} |
type | name | label | calculation |
select_multiple violations | violations | Code Violations | |
note | Violations observed | count-selected(${violations}) |
When calculating a note, you may want to have your text all be shown in one single line, rather than split in two like above. If that is the case, you can do something like the following:
type | name | label | calculation |
select_multiple violations | violations | Code Violations | |
note | </b> | concat("Violations: ", count-selected(${violations})) |
The only reason I use </b> in the label is because the label column is mandatory for a note. <b> will not render any text, so the main body of the note will read a a single line of text, which is what I want.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.