The Syncfusion native Blazor components library offers 70+ UI and Data Viz web controls that are responsive and lightweight for building modern web apps.
.NET PDF framework is a high-performance and comprehensive library used to create, read, merge, split, secure, edit, view, and review PDF files in C#/VB.NET.
Hi,
I am using a grid control and I have set the style of one of its columns to "MaskEdit". Here''s the code :
gcAjustements.ColStyles(COL_MOIS_IMPACT_NUM).CellType = "MaskEdit"
gcAjustements.ColStyles(COL_MOIS_IMPACT_NUM).MaskEdit.ClipMode = ClipModes.IncludeLiterals
gcAjustements.ColStyles(COL_MOIS_IMPACT_NUM).MaskEdit.DateSeparator = "/"
gcAjustements.ColStyles(COL_MOIS_IMPACT_NUM).MaskEdit.PromptCharacter = "*"
gcAjustements.ColStyles(COL_MOIS_IMPACT_NUM).MaskEdit.PassivePromptCharacter = "*"
gcAjustements.ColStyles(COL_MOIS_IMPACT_NUM).MaskEdit.PaddingCharacter = "*"
gcAjustements.ColStyles(COL_MOIS_IMPACT_NUM).MaskEdit.Mask = "##/####"
gcAjustements.ColStyles(COL_MOIS_IMPACT_NUM).MaskEdit.AllowPrompt = False
In fact, I want the user to type in a month and year, in the following format : MM/YYYY
**/**** is first shown and the * are replaced by what the user types in. If I do not respect the mask (like if *1/20** is shown), I get the message "Invalid Text: *1/20**" (which is good). However, I would like to customize this message, because my whole application is in french and I would want this message to also be in french.
Could you please tell me how to do so?
Thank you very much....
ADAdministrator Syncfusion Team September 10, 2004 03:07 PM UTC
Try handling the grid.ValidateFailed event. In your handler, you can the default message by checking grid.CurrentCell.ErrorMessage. You can also put your own text into grid.CurrentCell.ErrorMessage.