I notice that change scripts- for example on text inputs- are fired for every change, even during editing. So if this text needs to go into a DB, there is going to be an update SQL transaction for every letter typed. Is there any way to prevent this, such as script run on “committed value” only, or similar?
Look at the “Defer updates” property of the text input.
Where do I find that? It does not appear in the properties list in my Designer…?
I should have been more specific: in Perspective. And it looks like there is a topic already:
Sorry I didn't see this before submitting.
You can do this currently in a roundabout sort of way - although it might not be entirely safe depending on your use-case:
Instead of a change script, require a key-press Event (like Enter). Then use a script Action as part of the key-press Event to perform what needs to be done, including the self.props.text
property access.
Yes, I thought of that too, as well as similar “end” events like focus lost, but at least in Vision these did not work as well as the deferred updates. Will this be implemented in Perspective?
Deferred updates will definitely be in Perspective, but probably not for the 8.0 release.
8.1 is a likely candidate.