I am using Adobe Designer 10 and have used the Action functionality to configure my buttons.
Here is the problem:
The user is presented with a question:
Do you eat apples? Yes/No.
If the user selects the "Yes" checkbox, then the subform , "WhatKindofApples," is set to Visible and appears.
If the user eats more than one kind of apple, then the user should be able to add additional instances of "WhatKindofApples" by clicking the "Add Additional Apples" button.
If the subform, "WhatKindofApples," is set to Visible then the "Add Additional Apples" button works just fine.
If the subform is set to Hidden, then the Add button doesn't work.
So it seems like there is some sort of conflict between being able to add additional instances of hidden subforms once they become visible. I have include the Javascript from my form.
Here is the Javascript for the Add button:
form1.WhatKindofApples.AddAddlApples::click - (JavaScript, client)
//+ GENERATED - DO NOT EDIT (ID:0482B39E-E8D0-4F08-B313-E142D733EE1F CRC:2782582760)
//+ Type: Action
//+ Result1: AddInstance("$Node2")
//+ Node2: form1[0].WhatKindofApples[0]
//+ Node1: form1[0]WhatKindofApples[0].AddAddlApples[0]
//+ Condition1: Button("$Node1","click")
//+ ActionName: AddlEntityPrivate.click
this.resolveNode('form1._WhatKindofApples').addInstance(1);
if (xfa.host.version < 8) {
xfa.form.recalculate(1);
}
//-
Any help would be greatly appreciated!