build
build copied to clipboard
Better document the differences with ${xlsform} style interpolation
When building a form using the spreadsheet/XLSForm approach, you reference other fields with ${field_name}
, e.g.:
not(boolean(${gps_location})) or number(${gps_location})>15
But when specifying them in the online builder, I have to reference them with /data/field_name
, e.g.:
not(boolean(/data/gps_location)) or number(/data/gps_location)>15
Is this correct? I couldn't find this in the documentation - did I just miss it?
yeah, that's correct. xlsform sort of invents its own syntax to try to make things easier. when odk build was created (ten years ago!) i was shy about doing that sort of thing and just stuck as close to actual xforms as possible.
the documentation doesn't really talk about this much because.. it sort of used to just be the normal way of doing things! i don't think anybody really anticipated that xlsform might be so successful that people would learn it first and then have to switch to xforms to do stuff.
Thanks Issa, the documentation refers to accessing variables using the xlsform syntax, so it was really hard to work out what I had to do in the online editor. Any thoughts about where a note would be useful - in that doc or in the help for the online builder?
oh wow, i see. probably both?