How to hide default validation ToolTip of RadGridView

2 posts, 0 answers
  1. Narendar
    Narendar avatar
    2 posts
    Member since:
    May 2015

    Posted 04 May 2015 Link to this post

    Hi, I am using RadGridView to show the grid data. In CellValidating event handler I am validating the data and setting e.IsValid=false if data is not valid. It's displaying the red border and an empty tool tip on the corresponding cell. But I just need to display the red border if there is any invalid data. Can you tell me how can I do this, also provide any sample if there is any?
  2. Stefan X1
    Stefan X1 avatar
    482 posts

    Posted 07 May 2015 Link to this post

    Hello Narendar,

    For such customization you need to modify the template of the control. The proper way to achieve this is via Implicit Styles with NoXAML binaries. Please check the Setting a Theme(Using Implicit Styles) for more information on the matter.

    Modifying/removing the Validation tooltip depends on which validation approach is being used. You can check the Validating article for more information on the different types of data validation that RadGridView supports.

    In your case, since you validate data using CellValidating event, the validation is being performed in edit mode. In such scenario the Validation tooltip depends on GridViewEditorPresenter element. The different elements on which the Validation tooltip depends are described in the Styling Validation Tooltips article.

    So, for removing the Validation tooltip, please search for ControlTemplate with x:Key="GridViewEditorPresenter_ValidationToolTipTemplate". It is located in Telerik.Windows.Controls.xaml file. Within it you need to remove all VisualStateGroups inside VisualStateManager.VisualStateGroups.

    I hope this helps.

    Best Regards,

    See What's Next in App Development. Register for TelerikNEXT.

  3. DevCraft R3 2016 release webinar banner
Back to Top