Visual Basic (Declaration) | |
---|---|
Public Sub Refresh() |
Visual Basic (Usage) | Copy Code |
---|---|
Dim instance As ClientSideAction instance.Refresh() |
C# | |
---|---|
public void Refresh() |
Delphi | |
---|---|
public procedure Refresh(); |
JScript | |
---|---|
public function Refresh(); |
Managed Extensions for C++ | |
---|---|
public: void Refresh(); |
C++/CLI | |
---|---|
public: void Refresh(); |
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(); } } |
Using ClientSideAction to refresh WebGrid you only need one code like sample code above. The ClientSideAction is able to perform "cross-grid" operation where the grid in context (WebGrid1) is different with grid to refresh (WebGrid2). In previous version, you need to implement wgCustomActionResponse clientside event to parse the Xml result and then call the grid2's refresh client API to perform the refresh. With the ClientSideAction, wgCustomActionResponse is no longer required although the mechanism is still available to use.
Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family
Reference
ClientSideAction ClassClientSideAction Members
Tasks
How-to: Refresh Child Tables onlyHow-to: Refresh second Grid after invoking SendCustomRequest of first Grid