change store data and gridpanel refresh

  1. #1

    change store data and gridpanel refresh

    Hello

    Lets say i have method to select data from database - method is called selectsql(filter) where filter is my own filter using LIKE statement. method is returning datatable.
    And when the page loads everything is ok im using this code

    store1.datasource = selectsql("");
    store1.databind();
    and i have a textbox where i can write filter(this is simply company name) and button SEARCH. the code for directclick is:
    strore1.datasource = selectsql(textbox.text);
    store1.databind();
    and this is not working - why - when i write in page loads:
    store1.datasource = selectsql("WOL");
    store1.databind();
    this returns me what i want - all companies starting by WOL.

    Somethin is with refresh store or gridpanel - i try with CLEARMETA and REMOVEALL store methods and nothing changes.
    Last edited by Daniil; Jun 16, 2011 at 7:02 PM. Reason: Please use [CODE] tags
  2. #2
    now everything works, i forget to use


     
    if (!X.IsAjaxRequest)
    {
     
    store1.datasource = selectsql(""); 
    store1.databind();
     
     
    }
    in pageload method...

    please close this thread

Similar Threads

  1. Replies: 0
    Last Post: Mar 11, 2012, 9:20 AM
  2. [CLOSED] [1.0] refresh grid after change store with webmethod
    By PoloTheMonk in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: May 26, 2010, 4:20 AM
  3. Grid or Store won't refresh with new data!
    By Kamal in forum 1.x Help
    Replies: 1
    Last Post: Sep 22, 2009, 11:30 AM
  4. Replies: 1
    Last Post: Aug 24, 2009, 1:37 PM
  5. Replies: 4
    Last Post: Nov 17, 2008, 8:16 AM

Posting Permissions