Tuesday 8 January 2019

D365 get current record in form Control Event on button clicked

Get current record in form control event

[FormControlEventHandler(formControlStr(CustomForm, CustomButton), FormControlEventType::Clicked)]
public static void CustomButton_OnClicked(FormControl sender, FormControlEventArgs e)
{
// ds number 1 is for the first datasource
CustomTable callerRec = sender.formRun().dataSource(1).cursor();
}

thanks

No comments:

Post a Comment

AZURE INTERVIEW QUESTIONS AND ANSWERS

AZURE INTERVIEW QUESTIONS AND ANSWERES 2021 2. What is cloud computing? Explanation:  It is the use of servers on the internet to “store...