Create a lineedit field with the name "calculated_field" and don't set any datasource or field property. Put the following code in the onpush action of a button. The value you want to display has first be formatted with format_number and then be set with hk_dsdatavisible.set_value.
Example 5.5. calculated values
col1=hk_this.datasource().column_by_name("field_1") col2=hk_this.datasource().column_by_name("field_2") result=(col1.curval_asdouble()*col2.curval_asdouble()) calcfield=hk_thisform.get_pyvisible("calculated_field") calcfield.set_value(format_number(result, calcfield.use_numberseparator(),calcfield.precision()))