Set Field script step does not work properly in v10/v11
I have a database that have a script to save the edit to the comments. The users enter the edits in a global field xComment on the Edit layout. When they click on the Save Comment button, the current value in he xComment should be copied to a text field Comment.
This script works perfectly in v9, but doesn't work in v10/11. It appears the the edits in the global field does not get put in the Comment field by the Set field step. The comment field still has its original value (before edit) after the script runs.
I tried one solution by adding a Commit Record step at the beginning of the script. Then the script may work a few times. It's inconsistent.
Any idea of what could be the cause of this problem and any solution?