XLSforms generating errors in Commcare

Hi,

I am new to CommCare and interested in using it for the case mgmt feature.
I have already built xlsforms, which I wish to use as the follow up forms
in CommCare. I referred to the documentation below on how to load xml forms
into CommCare:
https://confluence.dimagi.com/display/commcarepublic/Use+Excel+to+Build+CommCare+Forms

My xlsforms convert to XML without error using the online converter at
(ODK - XLSForm Online v2.x). I loaded the .xml into CommCare via
Actions > XForms > Upload. Initially I get a warning 'Form does not have a
Version attribute (in the data block), one will be added automatically' but
otherwise they load ok. When I try to actually fill in the follow up form
either on the online formplayer 2.37 or the actual tablet app I receive the
following error(s):

Calculation Error: Error in calculation for /FormName/VariableName cannot
handle function 'once'
Calculation Error: Error in calculation for /FormName/VariableName cannot
handle function 'decimal-date-time'

The syntax listed in the error by CommCare ('once(), 'decimal-date-time',
...) are in the reference list at XLSForm.org under
calculation section and the forms seem to work without error in ODK and
Enketo.

I can certainly try to remove functions from my xlsforms that CommCare
doesn't support but is there way to know what is supported to ensure forms
are supported by CommCare? Should I use something like ODK Validate for a
previous version of ODK? If so, which version is appropriate for the
definition in use by CommCare?

Many thanks!

Hello,

We list our supported functions here
https://confluence.dimagi.com/display/commcarepublic/CommCare+Functions.
Probably the closest/easiest method we have to validate whether we support
certain functions this is the process you followed; namely, uploading the
form and seeing if CommCare errors or not.

Looking at the XLSForm docs the once() function seems similar to our notion
of a default value
https://confluence.dimagi.com/display/commcarepublic/Defining+a+Default+Value.
I can't tell from the docs what decimal-date-time does but you could likely
reproduce this behavior using the functions described here
https://confluence.dimagi.com/display/commcarepublic/Calculations+with+Dates+and+Times
.

Cheers,
Will

··· On Wed, Sep 20, 2017 at 4:03 PM, gid...@gmail.com wrote:

Hi,

I am new to CommCare and interested in using it for the case mgmt feature.
I have already built xlsforms, which I wish to use as the follow up forms
in CommCare. I referred to the documentation below on how to load xml forms
into CommCare:
https://confluence.dimagi.com/display/commcarepublic/Use+
Excel+to+Build+CommCare+Forms

My xlsforms convert to XML without error using the online converter at (
ODK - XLSForm Online). I loaded the .xml into CommCare via
Actions > XForms > Upload. Initially I get a warning 'Form does not have
a Version attribute (in the data block), one will be added automatically'
but otherwise they load ok. When I try to actually fill in the follow up
form either on the online formplayer 2.37 or the actual tablet app I
receive the following error(s):

Calculation Error: Error in calculation for /FormName/VariableName cannot
handle function 'once'
Calculation Error: Error in calculation for /FormName/VariableName cannot
handle function 'decimal-date-time'

The syntax listed in the error by CommCare ('once(), 'decimal-date-time',
...) are in the reference list at XLSForm.org under
calculation section and the forms seem to work without error in ODK and
Enketo.

I can certainly try to remove functions from my xlsforms that CommCare
doesn't support but is there way to know what is supported to ensure forms
are supported by CommCare? Should I use something like ODK Validate for a
previous version of ODK? If so, which version is appropriate for the
definition in use by CommCare?

Many thanks!

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

Thanks very much. This is helpful.

Ben

··· On Monday, September 25, 2017 at 1:45:14 PM UTC-4, William Pride wrote: > > Hello, > > We list our supported functions here > . > Probably the closest/easiest method we have to validate whether we support > certain functions this is the process you followed; namely, uploading the > form and seeing if CommCare errors or not. > > Looking at the XLSForm docs the once() function seems similar to our > notion of a default value > . > I can't tell from the docs what decimal-date-time does but you could likely > reproduce this behavior using the functions described here > > . > > Cheers, > Will > > On Wed, Sep 20, 2017 at 4:03 PM, gid...@gmail.com <gid...@gmail.com > wrote: > >> Hi, >> >> I am new to CommCare and interested in using it for the case mgmt >> feature. I have already built xlsforms, which I wish to use as the follow >> up forms in CommCare. I referred to the documentation below on how to load >> xml forms into CommCare: >> >> https://confluence.dimagi.com/display/commcarepublic/Use+Excel+to+Build+CommCare+Forms >> >> My xlsforms convert to XML without error using the online converter at ( >> http://opendatakit.org/xiframe/). I loaded the .xml into CommCare via >> Actions > XForms > Upload. Initially I get a warning 'Form does not have >> a Version attribute (in the data block), one will be added automatically' >> but otherwise they load ok. When I try to actually fill in the follow up >> form either on the online formplayer 2.37 or the actual tablet app I >> receive the following error(s): >> >> Calculation Error: Error in calculation for /FormName/VariableName cannot >> handle function 'once' >> Calculation Error: Error in calculation for /FormName/VariableName cannot >> handle function 'decimal-date-time' >> >> The syntax listed in the error by CommCare ('once(), 'decimal-date-time', >> ...) are in the reference list at http://xlsform.org/ref-table/ under >> calculation section and the forms seem to work without error in ODK and >> Enketo. >> >> I can certainly try to remove functions from my xlsforms that CommCare >> doesn't support but is there way to know what is supported to ensure forms >> are supported by CommCare? Should I use something like ODK Validate for a >> previous version of ODK? If so, which version is appropriate for the >> definition in use by CommCare? >> >> Many thanks! >> >> -- >> You received this message because you are subscribed to the Google Groups >> "commcare-users" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to commcare-user...@googlegroups.com . >> For more options, visit https://groups.google.com/d/optout. >> > >