on 10-20-2009 3:37 PM
Hi folks,
I'm using a button in a dynamic table to delete table rows. In the click event of this button I use the following JavaScript code to delete the table row:
this.parent.parent.instanceManager.removeInstance(this.parent.parent.instanceIndex); //parent.parent b/c there is another subform wrapping the button
The problem is that I have to recalculate a field outisde the table after the row has been delete. Unfortunately after calling the removeInstance method no more code is being executed, as (I think) the button already has been deleted.
Do you have any ideas how I can solve that problem? I already went through many events of the table/table row, but nothing is being executed after deleting the row.
Thanks & best regards,
Matthias
you can trigger events of a field by scripting -->
try to add in your coding, after having deleted the row
<field>.execCalculate();
<field> sould be replaced by the correct path....
norbert
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Chintan & Norbert,
thanks for your replies. That's exactly what I tried to do. I've written the code for calculating the field in the calculate event and tried to trigger it via calling the .execCalculate() method. The problem is, that this code is never being executed. After calling the .removeInstance() method the execution of the script stops (validated this via trying to open a message box afterwards).
Any other ideas or workarounds?
Thanks!
Matthias
You must write the code for recalculation in calculate event of the required field. For Eg: If I have a dynamic table Table1 and NumericField1 is the name of the field which displays Total of the values entered in Table1 then you must write the code in calculate event of NumericField1.
Also have a look at the Purchase Order Dynamic Interactive form in your Adobe Designer installation directory, that should give you some hints.
Chintan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.