# Error: calculate Question in a group, cause ArrayIndexOutBoundsException

**URL:** <https://forum.getodk.org/t/error-calculate-question-in-a-group-cause-arrayindexoutboundsexception/2489>\
**Category:** Support\
**Created:** [August 14, 2013, 5:10pm UTC](https://forum.getodk.org/t/error-calculate-question-in-a-group-cause-arrayindexoutboundsexception/2489 "2013-08-14T17:10:52Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ramon\_de\_la\_Cruz\_Laz](https://getodk.b-cdn.net/letter_avatar_proxy/v4/letter/r/b9e5f3/32.png) [@Ramon\_de\_la\_Cruz\_Laz](https://forum.getodk.org/u/Ramon_de_la_Cruz_Laz)\
**Post date:** [August 14, 2013, 5:10pm UTC](https://forum.getodk.org/t/error-calculate-question-in-a-group-cause-arrayindexoutboundsexception/2489/1 "2013-08-14T17:10:52Z")

</div>

However when you add a note in the group, the error disappears (see  
calculate\_group\_noerror.xls)

Ramon

[calculate\_group\_error.xls](https://getodk.b-cdn.net/uploads/default/original/1X/cebc426dfd4a9d2e2b6e3595b3da9aef92864b65.xls) (34 KB)

[calculate\_group\_noerror.xls](https://getodk.b-cdn.net/uploads/default/original/1X/c3179811de850e376f49057b213c1c30e8853111.xls) (34 KB)

---

<div class="post-metadata">

**Author:** ![Mitch\_S](https://getodk.b-cdn.net/letter_avatar_proxy/v4/letter/m/3ec8ea/32.png) [@Mitch\_S](https://forum.getodk.org/u/Mitch_S)\
**Post date:** [August 19, 2013, 5:08pm UTC](https://forum.getodk.org/t/error-calculate-question-in-a-group-cause-arrayindexoutboundsexception/2489/2 "2013-08-19T17:08:36Z")

</div>

The form with the error causes a failure in ODK Validate, so it is not  
surprising that it causes a problem on ODK Collect.

Running it through the online XLSForm, it produces:

Error: ODK Validate Errors: Group has no children! Group: ${gH}.

The XML is invalid. \>\> Xform is invalid!  
See above for errors and warnings.

> **···**
>
> On Wed, Aug 14, 2013 at 10:10 AM, Ramon de la Cruz Lazaro \< rmdlazaro@gmail.com\> wrote:
> 
> > However when you add a note in the group, the error disappears (see  
> > calculate\_group\_noerror.xls)
> > 
> > Ramon
> > 
> > ## --
> > 
> > Post: [opendatakit@googlegroups.com](mailto:opendatakit@googlegroups.com)  
> > Unsubscribe: [opendatakit+unsubscribe@googlegroups.com](mailto:opendatakit+unsubscribe@googlegroups.com)  
> > Options: [http://groups.google.com/group/opendatakit?hl=en](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](mailto:opendatakit+unsubscribe@googlegroups.com).  
> > For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).
> 
> --  
> Mitch Sundt  
> Software Engineer  
> University of Washington  
> [mitchellsundt@gmail.com](mailto:mitchellsundt@gmail.com)
