A data aware grid performs a save when changing rows and then refreshes the row values. So OnSetCalculatedValue will be executed again to determine the newly saved value. You probably want to implement OnSaveRow to store the entered value so that you can return it in OnSetCalculatedValue.