Wijmo Grid - Column drag and drop issue

Posted by: naresh.adla on 5 October 2021, 6:55 am EST

    • Post Options:
    • Link

    Posted 5 October 2021, 6:55 am EST

    Hi Team,

    We are using Wijmo licensed version in our product.

    When we have more number of columns in the grid we are not able to drag and drop a column to desired location. Because the horizontal scroll bar is not moving and I ended up multiple steps to get to a desired location.

    Ideally in one go I should be able to move a column to any location in the grid.

    Note: I have freezed first 4 columns in the grid.

    Please help !

  • Posted 6 October 2021, 3:51 am EST - Updated 3 October 2022, 12:25 pm EST

    Hi,

    We apologize for the inconvenience but we are unable to replicate the issue at our end. By dragging the item to FlexGrid left /right side, the column can be dragged to any specified position since in this case, the FlexGrid scrolls automatically.

    Please refer to the attached GIF for reference.



    Regards,

    Manish Gupta

  • Posted 6 October 2021, 7:27 am EST

    Thank you for your reply.

    Yes it is working fine only when we move the cursor to the end tip of the grid or start tip of the grid.

    But when we have few frozen columns the scroll should start moving as soon as we move mouse cursor on to the last frozen column.

    Is it possible ?

    Thanks.

  • Posted 10 October 2021, 4:02 am EST

    Hi Naresh,

    Please use the following code to scroll the columns as the mouse is hover on the Frozen Columns:

    
    /*var FlexGrid = wijmo.grid.FlexGrid;*/
    var _draggingOverColumn = FlexGrid.prototype.onDraggingColumnOver;
        FlexGrid.prototype.onDraggingColumnOver = function(e){
            var grid = e.panel.grid;
            if(grid.frozenColumns!=0 && e.col < grid.frozenColumns){
                e.cancel=true;
                var range = grid.viewRange;
                setTimeout(function(){
                    /* if(grid.viewRange.col-3 > grid.frozenColumns-1){*/
                        grid.scrollIntoView(range.row,range.col-2);
                    /* } */
                },100);            
            }
            return !e.cancel;
        }
    

    Hope it helps!

    Regards,

    Manish Gupta

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels