While searching through the forum to see if I could find some information regarding a problem with value-formatting while using a "DynaScrollTable" I came across this response by Dario Crivelli in a thread regarding the "addField" method:

Quote Originally Posted by DarioCrivelli
However, in the onChangingValues callback (the place where formatting instructions can be given to the VisualTable), the previous values of the updated fields are not available.
On the other hand, they are available in the onItemUpdate callback.
Out of curiosity, why did you chose to make the previous values available only in "onItemUpdate" and not in "onChangingValues"?

We actually are dealing with this "problem" on one of our sites at the moment. We have a "DynaScrollTable" receiving updates containing a timestamp, an identifier (string) and two decimal numbers. We need to format the numbers before displaying them (rounding decimal places, insert thousands separator - e.g. original value is "12345.6" and should be displayed as "12.345,600"), and it normally works like it should..

..but sometimes only one of the two numbers changes, so when our "onChangingValues"-function gets called I can't access the value that the unchanged field previously had, as "updateInfo.getFormattedValue("number2")" is "null". As we don't know the previous value we're not able to format it, and the unformatted value is displayed in the table.

Ideally I would write something like this in "onChangingValues":

..but I don't have access to the old value in "onChangingValues". At the moment the only way I see to get it to work would be to add some logic to the "onItemUpdate"-function, check if there are fields that did not change, and then add the old values of those fields via "UpdateItemInfo.addField(...)", so that I have the old value available in "onChangingValues" - I can't format the respective field in the "onItemUpdate"-function as I can read the value but not write it back into the field ("addField()" can only be used to add extra fields).

I don't really like this "solution" as it looks to me to be quite inelegant, but I don't see any other solution - perhaps I'm missing something simple or obvious as I assume that this is not an unusual use-case, but looking through the online documentation didn't give me some better idea yet.

Ideally, for an unchanged field, the table should just reuse the last set value of "setFormattedValue()" for the specific field, so my code could just ignore unchanged values, but the web client api doesn't seem to behave like this, at least on our site.

I also looked through the Changelog for the Web Client SDK, to see if there was some change or bugfix that related to formatted values, but I did not find anything there, either.

Any idea or comment is appreciated.