Refresh GridPanel data on postback event

  1. #1

    Refresh GridPanel data on postback event

    Dear All,

    I have a situation where i want to refresh my GridPanel on the Click event of a Button.
    I am trying to do it, but the GridPanel is not getting updated. This could be due to the data being already sent during the Load event of the page.

    But i want to refresh the GridPanel on Click event which is called after the Load event of the Page.
    How do i achieve this? Remember this is not a AjaxRequest its a Postback.

    Regards,
    Huzefa
  2. #2
    Please post simple test sample to demonstrate the issue
  3. #3

    Sample

    I have attached a simple sample which demostrates the issue i am facing.

    On load some data is attached to grid. Then on click Post button at bottom which is raises a postback event, this event will change the data for the grid.
    But when the page loads after the PostBack event i don't see the data being changed.
    I am sure i would be making some mistake, but not sure where is that mistake.

    Thanks vladmir and other ext.net guys for helping me out in so many occasions.


    Here the Link for download
    https://rapidshare.com/files/4058438...ackSample1.rar

    Thanks,
    Huzefa
    Last edited by huzzy143; Sep 05, 2011 at 6:41 PM.
  4. #4
    Why do you call reconfigure? Please remove it
    _grdMain.Reconfigure();
  5. #5

    Its Same

    Hi Vladmir,

    I removed the line

    _grdMain.Reconfigure();
    But still the data is not getting refreshed.
  6. #6
    Yes, it is bug. Store ignores second datasource
    Workaround:
    if(!IsPostBack)
    {
        BindData(Employee.GetAll());
    }
  7. #7
    Thanx Vladmir,
    The workaround solved the issue.

    Quote Originally Posted by Vladimir View Post
    Yes, it is bug. Store ignores second datasource
    Workaround:
    if(!IsPostBack)
    {
        BindData(Employee.GetAll());
    }

Similar Threads

  1. Replies: 0
    Last Post: Aug 07, 2012, 2:36 PM
  2. gridpanel lost data after postback
    By sonnh11 in forum 1.x Help
    Replies: 2
    Last Post: Jun 28, 2011, 10:31 AM
  3. change store data and gridpanel refresh
    By ven in forum 1.x Help
    Replies: 1
    Last Post: Jun 18, 2011, 6:28 AM
  4. [CLOSED] Exporting Data using Refresh event
    By ecerrillos in forum 1.x Legacy Premium Help
    Replies: 6
    Last Post: Sep 22, 2010, 3:32 PM
  5. Replies: 4
    Last Post: Nov 17, 2008, 8:16 AM

Tags for this Thread

Posting Permissions