Epi Info™ User Guide
Form Designer
How To: Use the Comment Legal Field
Comment Legal fields are similar to Legal Values. They are text fields with character(s) typed in front of the text (with a hyphen). During data entry, the character and the text (e.g. M-Male) are displayed. However, only the character value is stored in the table (e.g. M). In the Classic Analysis and Visual Dashboard tools, statistics can be calculated if all values are numeric. The following figure provides an example of how a Comment Legal field appears in Enter (circled in blue) based on the CaseReport form of the Lyme project.
To add a Comment Legal field:
- Open the Comment Legal Field Definition dialog box.
- Enter the Question or Prompt. The text entered in this field will display on the canvas and prompt the user to enter a response.
- Click in the Field Name text box or press the tab key. Epi Info automatically suggests a field name based on the Question or Prompt, however, it is very important that field names be short, intuitive, and usable. The field name is used for data validation in Check Code and when doing analyses. Field names cannot start with a number or contain any spaces or non-alphanumeric characters (except the underscore character “_” is permitted).
Note: It is best to simplify the field name at this time. Field names cannot be changed after data collection starts.
- Click the browse button to the right of the Data Source textbox.
- Click Create New to enter the available answers for the question.
- Enter the first value using the form code-hyphen-comment as in “M-Male” where “M” is the code and “Male” is the comment. Press Enter or Tab to advance to the next value.
- Enter additional values using the same code-hyphen-comment format until all necessary items are added to the drop-down list.
- Values will appear in alphabetical order unless you select Do Not Sort. This feature displays values in the order in which they are entered.
- Click OK.
- Existing tables can also be used to create Comment Legal fields.
- Click Create New from existing (takes a copy of selected table, changes to the original table will not affect the new table) or Use Existing (establishes a connection between the selected table and the new table, any changes made to the original table will modify the new table)
- Select a table from the drop-down list.
- Click OK.
For information on other attributes that may be available, see the topic on Field Attributes.
- From the Field Definition box, click OK. The new Comment Legal field appears in the form as a drop-down list of values.