Results 1 to 2 of 2

Thread: Highlighting current cell, after store.reload()

  1. #1
    Sencha User
    Join Date
    Jan 2011
    Posts
    47

    Lightbulb Highlighting current cell, after store.reload()

    I have grid, there i make some actions on 'afteredit' event of grid. Basicly - i need reload store, - to sync grid.
    Now - is a probelm, - how to restore cell position, - i.e. not start again editing, just move selection to current cell?

    Here is code:

    //make - entered - to be an index
    if ( e.field == "ste_adj" )
    {
    var val = make_idx ( e.value );
    e.record.set( e.field, val );
    e.record.commit();

    setTimeout(function(){
    store.reload();
    HERE is want restore HIGHLIGHT cell position ...


    }, 500);

    }

  2. #2
    Sencha Premium User mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    40,379

    Default

    You need to capture the selected cell (getSelectedCell() on the selection model may help) before store reload and then select() on the selection model to select that cell.
    Mitchell Simoens @LikelyMitch

    Check out my GitHub:
    https://github.com/mitchellsimoens

    Posts are my own, not any current, past or future employer's.

Posting Permissions

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