Insert/update Exception messages

Hello RadzenTeam,
i want to customize the Notification in Form Submit.

try
{
    var trentdbCreateFahrzeugResult = await Trentdb.CreateFahrzeug(fahrzeug);
    UriHelper.NavigateTo("fahrzeug");
}
catch (System.Exception trentdbCreateFahrzeugException)
{
    NotificationService.Notify(NotificationSeverity.Error, $"Error", $"Unable to create new Fahrzeug!");
}

The "Unabled to create ...." is not very informative. Especially duplicate key errors must be shown to the user. Otherwise the user will give us a call "Why cant i save ....?".

How can i customize the notification in form submit (or elsewhere)?

Kind Regards
Thomas

I see in the form submit event there is a possibility for this...
I will investigate. Sorry for the new Topic, it can be deleted.

Sorry
Thomas

Hi @Thomas,

No worries! Radzen generates event handlers that are executed when there is an error in the Invoke data source method. You can change the error message there as you wish.