earthwiseaware / field_surveys

XLSForms for our field surveys
0 stars 0 forks source link

Limiting the number of photo records in a survey #32

Closed Cloneill-2021 closed 2 years ago

Cloneill-2021 commented 2 years ago

There should be a way to restrict the number of photo records (Google forms allow that for sure, as well as ArcGIS if I am correct). I am not finding how to do it.

mgietzmann commented 2 years ago

https://xlsform.org/en/#fixed-repeat-counts

Cloneill-2021 commented 2 years ago

I'll try that too :-)

On Mon, Aug 8, 2022, 10:04 PM Marcel Gietzmann-Sanders < @.***> wrote:

https://xlsform.org/en/#fixed-repeat-counts

— Reply to this email directly, view it on GitHub https://github.com/earthwiseaware/field_surveys/issues/32#issuecomment-1208827946, or unsubscribe https://github.com/notifications/unsubscribe-auth/AY4PD7YPNSMOXWJCZCGUAFTVYG4EBANCNFSM5525TQDQ . You are receiving this because you authored the thread.Message ID: @.***>

Cloneill-2021 commented 2 years ago

Hmmmm.... This one imposes a number of repeats. Can we impose an upper limit only. That is, not more than 3 pics for instance. 1 photo is ok, but not more than 3. I search for keywords s.s. 'max', or 'upper', or 'less'. But there must be sth though (Google forms have that feature for instance).

In other words, the question is: how to limit the number of image files allowed in an xlsform?

mgietzmann commented 2 years ago

See this section of the ODK documentation: https://docs.getodk.org/form-repeats/#using-relevants-to-limit-repetitions

Basically instead of using a repeat at all you can specify say 5 image questions in a row but use a condition to only make them viewable when the last image was input.