Intersoft WebGrid Documentation
How-to: Refresh second Grid after invoking SendCustomRequest of first Grid
See Also Send comments on this topic.

Glossary Item Box

You only need one code to perform refresh to Grid2. The ClientAction engine is able to perform "cross-grid" operation where the grid in context (WebGrid1) is different with grid to refresh (WebGrid2).

In this topic, you will learn the basic thing on how to refresh second grid after invoking OnTheFlyPostBack of first grid.

To refresh second WebGrid after SendCustomRequest

  1. Go to WebGrid properties, server side event.
  2. Attach the WebGrid InitializePostBack event into the WebGrid.
  3. Inside of the e.Action == PostBackAction.Custom condition, use ClientAction engine to perform a client side Refresh method.
  4. C# Copy Code
    private void WebGrid1_InitializePostBack(object sender,ISNet.WebUI.WebGrid.PostbackEventArgs e)
    {    
       if (e.Action == PostBackAction.Custom)    
       {        
          // perform business logic here        
          WebGrid2.ClientAction.Refresh();    
       }
    }
    
  5. Run the project.

See Also

©2012 Intersoft Solutions Corp. All Rights Reserved.