GridRefresh - cWebList

Send this message to fire an action on the client telling it to refresh the grid (for non-data-aware grids only)

Type: Procedure

Parameters: None

Syntax
Procedure GridRefresh 

Call: Send GridRefresh


Description

Send this message to fire an action on the client telling it to refresh the grid.

If the grid is manually loaded (pbDataAware = False or peDbGridType = gtManual), GridRefresh will also call OnManualLoadData.

You should not call this for a data-aware list!

The OnManualLoadData event is not automatically fired. You will need to write code in your view to trigger it. Typically, you would augment the grid or list's OnLoad event to do this by signaling the client to perform a GridRefresh. This will load the grid data loaded in OnManualLoadData when the grid is first activated.

Procedure OnLoad
    Forward Send OnLoad    
    Send GridRefresh
End_Procedure

In the above example, the grid's OnLoad event will signal the client that the grid needs to refresh its data. The client will respond to this by sending the OnManualLoadData event to the server and will populate its rows with the returned data set.

If you wish to manipulate a manually loaded grid's data and refresh the grid's data from a specific user action, for example a button click, you must also call GridRefresh:

Procedure OnClick
    Send GridRefresh of oWebResultsGrid
End_Procedure