Validating a String

Dear ODKers,

Hi I have choice list of crops as follows:

Maize
Beans
Sugarcane
Surghum

I want to set a constraint such that when beans is picked at loop 1, it
should warn that "Invalid choice. Beans is not the right option"

I have done this in xlsform but its not giving me what i wanted. The crops
names have to be in strings as shown above

constraint
Constraint Message
.!="Beans" Oops! Invalid crop. You cannot select beans at this point. Any
idea on how to go about it will be highly appreciated.

Collins

I assume the issue is that the custom constraint message is not being shown?

The column name for the constraint message text needs to be
constraint_message

··· On Thu, Mar 6, 2014 at 5:21 AM, Collins McAdoyo wrote:

Dear ODKers,

Hi I have choice list of crops as follows:

Maize
Beans
Sugarcane
Surghum

I want to set a constraint such that when beans is picked at loop 1, it
should warn that "Invalid choice. Beans is not the right option"

I have done this in xlsform but its not giving me what i wanted. The crops
names have to be in strings as shown above

constraint
Constraint Message
.!="Beans" Oops! Invalid crop. You cannot select beans at this point. Any
idea on how to go about it will be highly appreciated.

Collins

--

Post: opendatakit@googlegroups.com
Unsubscribe: opendatakit+unsubscribe@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en


You received this message because you are subscribed to the Google Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to opendatakit+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

--
Mitch Sundt
Software Engineer
University of Washington
mitchellsundt@gmail.com

Thanks Mitch. Well the problem is its accepting beans and not giving me
error message like i expected.

Collins

··· On Mar 6, 2014 4:21 PM, "Collins McAdoyo" wrote:

Dear ODKers,

Hi I have choice list of crops as follows:

Maize
Beans
Sugarcane
Surghum

I want to set a constraint such that when beans is picked at loop 1, it
should warn that "Invalid choice. Beans is not the right option"

I have done this in xlsform but its not giving me what i wanted. The crops
names have to be in strings as shown above

constraint
Constraint Message
.!="Beans" Oops! Invalid crop. You cannot select beans at this point. Any
idea on how to go about it will be highly appreciated.

Collins

--

Post: opendatakit@googlegroups.com
Unsubscribe: opendatakit+unsubscribe@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en


You received this message because you are subscribed to the Google Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to opendatakit+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Double-check your choices shet, see if you're comparing the name, not the
label for "Beans"

··· On Friday, March 7, 2014, Collins O. Adoyo wrote:

Thanks Mitch. Well the problem is its accepting beans and not giving me
error message like i expected.

Collins
On Mar 6, 2014 4:21 PM, "Collins McAdoyo" <collins.adoyo@gmail.com<javascript:_e(%7B%7D,'cvml','collins.adoyo@gmail.com');>> wrote:

Dear ODKers,

Hi I have choice list of crops as follows:

Maize
Beans
Sugarcane
Surghum

I want to set a constraint such that when beans is picked at loop 1, it
should warn that "Invalid choice. Beans is not the right option"

I have done this in xlsform but its not giving me what i wanted. The
crops names have to be in strings as shown above

constraint
Constraint Message
.!="Beans" Oops! Invalid crop. You cannot select beans at this point. Any
idea on how to go about it will be highly appreciated.

Collins

--

Post: opendatakit@googlegroups.com<javascript:_e(%7B%7D,'cvml','opendatakit@googlegroups.com');>
Unsubscribe: opendatakit+unsubscribe@googlegroups.com<javascript:_e(%7B%7D,'cvml','opendatakit%2Bunsubscribe@googlegroups.com');>
Options: http://groups.google.com/group/opendatakit?hl=en


You received this message because you are subscribed to the Google Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to opendatakit+unsubscribe@googlegroups.com<javascript:_e(%7B%7D,'cvml','opendatakit%2Bunsubscribe@googlegroups.com');>
.
For more options, visit https://groups.google.com/groups/opt_out.

--

Post: opendatakit@googlegroups.com<javascript:_e(%7B%7D,'cvml','opendatakit@googlegroups.com');>
Unsubscribe: opendatakit+unsubscribe@googlegroups.com<javascript:_e(%7B%7D,'cvml','opendatakit%2Bunsubscribe@googlegroups.com');>
Options: http://groups.google.com/group/opendatakit?hl=en


You received this message because you are subscribed to the Google Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to opendatakit+unsubscribe@googlegroups.com<javascript:_e(%7B%7D,'cvml','opendatakit%2Bunsubscribe@googlegroups.com');>
.
For more options, visit https://groups.google.com/d/optout.

--

Nik
Need help customizing Survey Instruments/Tools/Forms for ODK Collect? Drop
me an email.

Double-check your choices shet, see if you're comparing the name, not the
label for "Beans"

··· On Friday, March 7, 2014, Collins O. Adoyo wrote:

Thanks Mitch. Well the problem is its accepting beans and not giving me
error message like i expected.

Collins
On Mar 6, 2014 4:21 PM, "Collins McAdoyo" <collins.adoyo@gmail.com<javascript:_e(%7B%7D,'cvml','collins.adoyo@gmail.com');>> wrote:

Dear ODKers,

Hi I have choice list of crops as follows:

Maize
Beans
Sugarcane
Surghum

I want to set a constraint such that when beans is picked at loop 1, it
should warn that "Invalid choice. Beans is not the right option"

I have done this in xlsform but its not giving me what i wanted. The
crops names have to be in strings as shown above

constraint
Constraint Message
.!="Beans" Oops! Invalid crop. You cannot select beans at this point. Any
idea on how to go about it will be highly appreciated.

Collins

--

Post: opendatakit@googlegroups.com<javascript:_e(%7B%7D,'cvml','opendatakit@googlegroups.com');>
Unsubscribe: opendatakit+unsubscribe@googlegroups.com<javascript:_e(%7B%7D,'cvml','opendatakit%2Bunsubscribe@googlegroups.com');>
Options: http://groups.google.com/group/opendatakit?hl=en


You received this message because you are subscribed to the Google Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to opendatakit+unsubscribe@googlegroups.com<javascript:_e(%7B%7D,'cvml','opendatakit%2Bunsubscribe@googlegroups.com');>
.
For more options, visit https://groups.google.com/groups/opt_out.

--

Post: opendatakit@googlegroups.com<javascript:_e(%7B%7D,'cvml','opendatakit@googlegroups.com');>
Unsubscribe: opendatakit+unsubscribe@googlegroups.com<javascript:_e(%7B%7D,'cvml','opendatakit%2Bunsubscribe@googlegroups.com');>
Options: http://groups.google.com/group/opendatakit?hl=en


You received this message because you are subscribed to the Google Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to opendatakit+unsubscribe@googlegroups.com<javascript:_e(%7B%7D,'cvml','opendatakit%2Bunsubscribe@googlegroups.com');>
.
For more options, visit https://groups.google.com/d/optout.

--

Nik
Need help customizing Survey Instruments/Tools/Forms for ODK Collect? Drop
me an email.