Actions After Add, Edit, Save
Modifying Values before Saving Data

Description
This customization shows how to modify the values of a record field before saving the data.
Variables
Record Control
Select a record control where this customization will be added.
Table Name
Select a table for this customization.
Field Control
Select the field to be modified
Applies to
RecordControl class
Code
 
/// 
/// Override the default behavior of the GetUIData(). The following code example uses the ${Table Name} table
/// and modifies the ${Field Control} field value to "new value".
/// 
public override void GetUIData()
{        
    // Call base.GetUIData()
    base.GetUIData();
	 
    // Get ${Table Name} Record
    ${Table Name}Record myRec = this.GetRecord();
		
    // Set ${Field Control} field value to new value string
    myRec.${Field Control} = "new value";    
    
}

     


  Privacy Statement