Dear all,
I have a report that shows some data in a dialog in a Table. Now I also have a button in the dialog to replace the data in that table:
var data = [];
data.push([true, "test", "test", "test", "test"]);
this.dialog.getPage(0).getDialogElement("DetailsTable1").setItems(data);After running the code I expect the table to be updated, but it never gets updated.
I have another simple test button that does the following:
this.dialog.getPage(0).getDialogElement("DetailsTable1").addRow();This adds a simple row and does work.
What do I need to do update the table with new data after a button click?
Kay Fischbach on
The
itemsparameter ofTable.setItemssays in the ARIS Report script referenceSince your
datastarts with the valuetruewhich is of typeBooleaninstead ofStringthe result of the method is undefined behavior.Edit: if you just want to print "true" in the table, replace
truewithString(true). Otherwise create a function that takes aBooleanas an argument and returns the string you want to print and replacetruewith the function call.