Hi All,
We have encountered a problem in our application in regards to onRecordEditStart event getting triggered inappropriately.
I have two forms open in two windows next to each other and a combobox in one of them. I click on the combobox and select a value from the list. The click will call onRecordEditStart, which is fine. After I chose the value from the list, I don’t do anything else on this form and click on my other form that is open in another window.
I have a onFocusLost function on the combobox that saves the data. So when I switch to the other form, the focus is gone and the data is saved. All good so far. Now I click on the title bar of my first window with the combobox. At this moment the focus goes back to the combobox and the onRecordEditStart event gets triggered again.
The problem is that my form with the combo has a toolbar with action buttons and when onRecordEditStart is fired, my buttons switch into editing mode - so navigation buttons get disabled and save/cancel buttons come forward.
The user is very confused at this point because they didn't edit the record and they want to go next or previous record in the foundset or maybe add a record or do whatever the toolbar should allow them. But they cannot, because they need to save or cancel now - and, again, they didn't change anything. This is when the user goes in panic mode.
Long time ago we requested to change the behaviour of onRecordEditStart to be only fired if the user changed a value, not just clicked in the field. Servoy refused to do so. Now this behaviour really lacks logic and we would like to bring up this issue again.
We already had to simulate the standard 'interactive change' event, available in FoxPro, but somehow not in Servoy. However, we could only do that on text fields with the help of the key listener plugin; simulating that on comboboxes, radios, etc. is harder because Servoy doesn't provide a mouse listener plugin. Overall, we'd be much happier if we just had the proper Interactive Change event or have onRecordEditStart only fired when data is changed.
The user experience is paramount in making an application usable, and at this point we continue to have a significant difficulty creating a usable application.
Could someone from Servoy, please, comment on this issue and perhaps look into the possibility of implementing the requested changes.
I have attached a sample solution to show this behaviour.