Instructions

android

Introduction

Creating a project

Form Builder

Adding a Form
          Key Field
          Title

Text Fields
          Plain

          Numeric
          Date
          Time
          Drop-Down
          Radio 
            Check Boxes
          
Media Fields
           Location

           Photo
           Video
           Audio
           barcode

Validation
           Text
           RegEx   
           Double Entry

Form Logic
           Jumps


Linking Forms
           Hierarchy

           Branching

android


Installing EpiCollect+
Loading a Project


Collecting Data

Text Fields
          Plain

          Numeric
          Date
          Time
          Drop-Down
          Radio
             Check Boxes

Media Fields
           Location

           Photo
           Video
           Audio
           barcode

Saving Data

List/Sync data

Maps

Backing up data

Remote Data

Settings

android


Project Website

Map View

Multiple Forms

Downloading Data

android


Introduction

EpiCollect Markup

The Document
           <model>

The Form
           <form>


Text Fields
           <input>

          <select>
           <select1>
          <radio>
Setting defaults

Media Fields
           <location>
           <photo>
           <video>
           <audio>
           <barcode>

Defining keys

Form Logic
           Jumps


Linking Forms
           Hierarchy

           Branching
  
Validating



Adding a branch Form

There may be cases when data you wish to collect within a form does not fall into the hierarchical structure previously described.

EpiCollect+ provides another method of adding flexibility that we describe as ‘branch forms’. 

Briefly, a branch form is one that is not within the overall hierarchy, but can be linked to a form at some level in the hierarchy, and can be completed none, one or more times. 

 

Defining a branch Form

As an example, within the teacher form in our demo project, we may wish to collect data on each teacher's absences during the year due to sickness. 

In this case we would have a question on the teacher form asking the number of episodes of absence due to sickness. Some teachers may answer ‘none’ and some may answer 1, 2, 3 etc.

Branch forms allow us to define a new form (in this case about sickness (form D)), outside the hierarchical structure, that appears once or more times in response to a the answer in another form (as in the following figure).

branch

Defining a branch form in your XML

 

<form num= "1" name="School" key="Schoolname">

	<input ref="Schoolname" title="true">
	   
	   <label>what is the school's name?</label>

	</input>

</form>

<form num="2" name="Teacher" key="Teachername">

	<input ref="Teachername" title="true">
	
	   <label>what is the teacher's name?</label>
	
	</input>

	<input ref="Schoolname" title="true">
	
	   <label>what is the school's name?</label>
	
	</input>

<form num="3" name="Pupil" key="Pupilname">

	<input ref="Pupilname" title="true">
	
	   <label>what is the pupil's name?</label>
	
	</input>

</form>

<form num="4" name="Sickness" main="false" key="Sicknesskey">

	<input ref="SicknessID" keygen="true" display="false">
	
	   <label>Sickness ID</label>
	
	</input>

	<input ref="Dateofsickness" setDate="true">
	
	   <label>Enter start date of absence</label>
	
	</input>

	<input ref="DaysSickness" integer="true">
	
	   <label>How many days were you absent</label>
	
	</input>

</form>

 

The sickness branch form is very simple and of course in a real world project, questions such as 'reason for absence' could be specified with a <select1> dropdown etc. However, the key message is that a branch form can be utilised for gathering information from within a form in the main hierarchy. A user may not need to fill in the branch, or they may fill in the branch form one or multiple times.

 

stuff below seems to be from a previous page

 

Note: We have set the title="true" attribute on each of the key fields for each table - Remember, this is what is shown to you when you list or view entries on the handsets.

In the example above, the key for the School form is set as the Schoolname input, in the Teacher form, the key is set as the Teachername input and in the Pupil Form, the key is set as the Pupilname input.

This means that all Schoonames must be unique (and a user will be warned should they attempt to create a new entry with the same Schoolname as an existing entry) all Teachernames for a particular school must also be unique and all pupil names for a particular teacher must be unique.

The forms are numbered in the order they appear in the hierarchy (1,2 and 3) meaning that many teacher entries can be added for each School entry and many pupil entries can be entered for a particular teacher. To define the link, the unique key field(Schoolname) is placed within the Teacher form as an input to define the link between School and teacher. This means that every Teacher entry will include the unique reference (Schoolname) or the School it is attached to. Similarly, to link the pupilform to the Teacher form, the 'Teachername' key from the Teacher Form is placed in the Pupil form.

In the example above, a user adding a teacher will be presented onscreen with the Schoolname that teacher has been assigned to as the first question - The schoolname will be filled in automatically as in the following screenshots

The flow of data entry for this two table example is shown in the following screenshots:

Click here to open large-scale view of workflow

 

2

The initial view lists the forms within your hierarchy. Tapping takes you to the menu for that particular form.

 

In this example, we tap on School which takes us to the School Form menu

     
ard        
To add a School entry, tap 'Add'   This is the School Form 'key' we defined above   To store the School entry tap 'Store'
3

 

 

 

arrow

4

 

 

 

arrow

5
                        ard
 
ard   ard
We can now add another School or We can add a teacher to this School
6
 
7
To add a Teacher entry, tap 'Add'   Note: the School Form Key is included   This is the Teacher Form 'key' we defined above   To store the Teacher entry tap 'Store'
8

 

 

 

arrow

9

 

 

 

arrow

10

 

 

 

arrow

11
            ard
 
12
  After storing, we can either add another teacher for this school or go back and select a different school to add further teacher forms to.

 

 

 

 

Next | Validating