I have a perspective table with a variety of calculations/queries to determine cell values. I have two dropdowns that are driving these calculations/queries. When I make a change to one of the dropdowns, the cells values update in a random order, and even display intermediate values. Does anyone know if there is a way to make this component rendering refresh only after all of the calculations/queries are complete?
@wking The table responds the same way whether I have props.virtualized set to true or false.
You can call a .refreshBinding(“propertyName”) on the control you’re updating. Code would look something like this. self.getSibling(“Table”).refreshBinding(“props.data”)
Depending on the situation I will sometimes put a message handler on a control that calls refreshBinding on the data element and then I can call that message handler if something happens that requires the binding to update.
That said, it’s often a better option to make sure that the control you’re updating is deriving its output using whatever triggers the update in a binding so the binding is refreshed when that value changes.
Look into “Expression Structure” bindings. They work kind of like a subroutine call where the parameters trigger your script to refresh itself. They’re really powerful and can streamline your app if they are the right fit. It sounds to me like you could use an Expression Structure binding and then populate your dataset using a script transform.
The ideal method to refresh your contents varies based on what you’re trying to do.