Expand my Community achievements bar.

SOLVED

Second instance copying a single value from first instance. All following act normal.

Avatar

Level 2

SubFormA

TableA

DropDownList1

DropDownList2

TextName

DateToday

NumericAlpha

NumericaBeta

ButtonDelete

./TableA

ButtonAdd

/SubformA

Each field (denoted in bold) is mapped to a schema.  All non-bold items have bindings of "None"  TableA has a default binding of None and is set to repeat for each data item with no min count, no max, and no initial count.

When I click my "ButtonAdd' I create a new instance of TableA via  "_TableA.addInstance(true);" and I remove the instances via ButtonDelete: "_TableA.removeInstance(this.parent.index)"

Pretty straight foreward so far.

The problem is this: When I add a second instance of TableA, DropDownList1 copies the value from the first instance.  Furthermore, if I pick a new choice in DropDownList1 from either instance, the change is reflected in the other.  No other values are mirrored like this.  Furthremore, if I add a thrid, fourth, etc instance, these instances work indipendently as expected.  Lastly, if I remove the first two instances via ButtonDelete, all remaining instances continue to act normally.

I've no idea why this is happening.  Any ideas?

1 Accepted Solution

Avatar

Correct answer by
Former Community Member

TableA needs to be bound to the repeating parent node in your schema.

Paul

View solution in original post

2 Replies

Avatar

Correct answer by
Former Community Member

TableA needs to be bound to the repeating parent node in your schema.

Paul

Avatar

Level 2

Thank you! Two days of frustration solved.  That was more annoying that trying to find a missing semicolon!

The following has evaluated to null or missing: ==> liqladmin("SELECT id, value FROM metrics WHERE id = 'net_accepted_solutions' and user.id = '${acceptedAnswer.author.id}'").data.items [in template "analytics-container" at line 83, column 41] ---- Tip: It's the step after the last dot that caused this error, not those before it. ---- Tip: If the failing expression is known to be legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)?? ---- ---- FTL stack trace ("~" means nesting-related): - Failed at: #assign answerAuthorNetSolutions = li... [in template "analytics-container" at line 83, column 5] ----