Cells in a GridViewDecimalColumn are prohibited from using up or down buttons

3 posts, 1 answers
  1. Ricardo
    Ricardo avatar
    22 posts
    Member since:
    Dec 2018

    Posted 07 May 2019 Link to this post

    Hello, my friend

    Look at the picture below, I want to remove these two buttons, what should I do?

  2. Answer
    Dimitar
    Admin
    Dimitar avatar
    2841 posts

    Posted 08 May 2019 Link to this post

    Hello Ricardo,

    You should use the CellEditorInitialized event to access the editor an hide the arrow buttons:
    private void RadGridView1_CellEditorInitialized(object sender, Telerik.WinControls.UI.GridViewCellEventArgs e)
    {
        var editor = e.ActiveEditor as GridSpinEditor;
        if (editor != null)
        {
            var element = editor.EditorElement as RadSpinEditorElement;
            element.ShowUpDownButtons = false;
             
        }
    }

    I hope this will be useful. Let me know if you have additional questions.

    Regards,
    Dimitar
    Progress Telerik
    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
  3. Ricardo
    Ricardo avatar
    22 posts
    Member since:
    Dec 2018

    Posted 09 May 2019 Link to this post

    Hello, my friend

    Thank you for your reply. It works very well

    Best wishes to you!

Back to Top