Editable Grid with dateField not updating due to index.

I am configuring an editable grid. I have a couple readOnly fields that get populated based on what the user selects in one of the other editable fields.

In this specific case, if the user selects a specific account number (the dropDownField(), the textfield above this gets updated. This field updates correctly. However, I get an error with that same if() statement for the dateField. How do I resolve this. See attached for code snippet and error.

 Discussion posts and replies are publicly visible