I have created a form that has a cyclic list a radio button (or boolean, it doesn't matter) and several float fields.
For instance I have
var1 float_field11 float field12
var2 float_field21 float field22
I would like to
1) change the editable property of each float_fieldx1 depending on the value of the cyclic list
2) change the editable property of each float_fieldx2 depending on the value of the corresponding float_fieldx1 and the value of the radio button (all disable if radio os on "Off" position.
I managed to implement 1) but I'm having trouble in getting 2) to work.
As of now I'm using two different callbacks for the cyclic fields and the radio button.
It lookd like my code works fine when the cyclic list has few elements, however, when the list grows up it doesn't refresh the fields anymore.
Any help is very appreciated.
The code appeared to have a couple of (what I assume were) mistakes. In the function exUpdateFloatFields it seemed to be leaving the cyc11stFloatField enabled when cyc3 and cyc4 were chosen - which I assume was not what you wanted. I've modifed that and uploaded - but I'm not sure if that was what you were complaining about?You could almost certainly write the code to figure out the field names to enable/disable from the cyclic value, which would avoid the big case statement, but I don't think that's what you were asking - I'm assuming you're expecting just one of the four sets of float fields to be enabled at once - if so, that was the coding error which I corrected in the attachment.Andrew.
thanks for your reply. However, I put multiple activation at once on purpose. I now solved the issue by using hiUpdateFormBlock(form) inside the exUpdateFormFields. I found that in the regular documentation.