Results 1 to 3 of 3

Thread: How to get the row index of a grid having only a XY position ?

  1. #1
    Sencha User
    Join Date
    Mar 2011

    Question How to get the row index of a grid having only a XY position ?

    I'm trying to get the row index of a grid when I drag&drop an image into it.
    For esthetic reasons, the drag element has no offset, so when I move it, it sticks right under the mouse cursor. This is not negociable.
    Consequently on the nodeDrop event, the result of event.getTarget() is actually the dragged image

    So basically I only have got the event.getXY() to know where the image is dropped.

    So I need to know how to get the rowIndex of a grid having only an XY position ? (Unless someone know how to get the event target beyond the dragged image ?)

  2. #2
    Sencha User sword-it's Avatar
    Join Date
    May 2012



    Could you please send a piece of your code in order to understand your problem more specificly.

    Thx, Sencha Developer House in Turkey - Istanbul University Technopark Suite 204.

  3. #3


    try with gridview.indexOf(node) it will return the index of that particular node, you can get the node either by doing something like gridview.getSelectedNodes()[0] (first selected node) or if you are using the dragdrop plugin, the drop event of the plugin also passes the affected node.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts