Answered
I have a simple piece of code inside the 'exit'-event of a number field that I can't figure out why it's not working. The intention is that the user will enter a number inside the number field, and upon exiting the field, a subform will be repeated the number of times equivalent to the number written by the user. Here is the code:
var count = NumberOfCases.rawValue;
for (var i = 0; i < count; i++) {
xfa.form.form1.Main_subform.subform1.subform2.InstanceManager.addInstance(true);
}
I'm suspecting there is some simple thing I have overlooked :P
By the way.
You better name your variables with individual name. The name "count" is a reseved for a function in LCD, and should not be used for a variable.
radzmar
• LoveCycle Blog
Documents you need:
• LiveCycle Designer ES2 Docs