We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
Unfortunately, activation email could not send to your email. Please try again.
Essential JS2

Syncfusion jQuery based widgets are no longer in active development. Switch to our pure JavaScript based next generation Essential JS 2 library.

Syncfusion Feedback

How to customize the drag icons while Drag and Drop

Platform: jQuery |
Control: ejTreeGrid |
Published Date: September 27, 2018 |
Last Revised Date: May 29, 2019

 

TreeGrid allows us to customize the row drag and drop indicators and we can achieve this by defining custom styles in the below class names of the HTML elements.

  • e-aboveIcon e-icon - Class name to define the insert above drop icon.
  • e-belowIcon e-icon - Class name to define the insert below drop icon.
  • e-childIcon e-icon - Class name to define the insert as child row drop icon.
  • e-cancelIcon e-icon - Class name to define the row drop restricted icon.

 

The below code snippet explains how to customize the row drag icons

<style>
        .e-treegrid .e-aboveIcon,.e-treegrid .e-belowIcon,.e-treegrid .e-childIcon,.e-treegrid .e-cancelIcon{
            color:red;
        }
            .e-treegrid .e-aboveIcon:before, .e-treegrid .e-belowIcon:before, .e-treegrid .e-childIcon:before, .e-treegrid .e-cancelIcon:before {
                font-size: 24px;
            }
</style>
< body>     
<div id="Container" style="width:100%;height:450px;" /> 
<script type="text/javascript"> 
$(function () { 
            $("#Container").ejTreeGrid({   
                dataSource: data, 
                //.. 
                            allowDragAndDrop:true,
                }, 
            }); 
        }); 
    </script>   
< /body>         

The below screenshot depicts the color customized row drop icon in TreeGrid

Customize the row drag and drop icons in treegrid.

You can find a sample for customizing the row drag and drop icons in TreeGrid here.

 

 

ADD COMMENT
You must log in to leave a comment

Please sign in to access our KB

This page will automatically be redirected to the sign-in page in 10 seconds.

Up arrow icon

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile