|
|
|
|
|
<Table>.RefreshVisible (Función) Modifies or returns the visibility status of refresh bar in a Table or TreeView Table control. This function can be used when the Table control supports the "Pull-to-refresh" option. To enable this option in a Table control: - Open the Table control description window.
- On the "Details" tab, in the "Moves and gestures" area, check "Deslizar hacia abajo para actualizar (Pull to refresh)".
- Validate.
// "Pull to refresh" process of Table control // --------------------------------------------------------- // Check the display of selection bar because the refresh of // Table control data will be performed in a secondary thread. // Otherwise, the refresh bar would be automatically hidden at the // end of process execution. TABLE_Data.RefreshVisible(True) // Refreshes the data of Table control in a secondary thread ThreadExecute("ThreadUpdTable", threadNormal, ProcThreadUpdTable)
//---------------------------------------------------- // Procedure used to update the data in the Table control PROCEDURE ProcThreadTableUpdate() // Run an HTTP request HTTPRequest(...) // Goes back to the main thread to add the request content into the Table control ExecuteMainThread(ProcUpdTable, HTTPGetResult()) END
// --------------------------------------------------- // Procedure for filling data in the Table control PROCEDURE ProcUpdateTable(sData is string) // Process the received data in order to populate the Table control ... // The Table control data is updated, hide the refresh bar TABLE_Data.RefreshVisible(False) END
Sintaxis
Cambiar el estado de la barra de actualización Ocultar los detalles
<Table control>.RefreshVisible(<Visible>)
<Table control>: Nombre del control Name of the control to be used. This field may correspond to: - a Table control.
- a TreeView Table control.
<Visible>: booleano - True to display the refresh bar,
- False to hide it.
Obtener el estado de la barra de actualización Ocultar los detalles
<Result> = <Table control>.RefreshVisible()
<Result>: booleano - True if the refresh bar is displayed,
- False if the refresh bar is hidden.
<Table control>: Nombre del control Name of the control to be used. This field may correspond to: - a Table control.
- a TreeView Table control.
Observaciones - During a "Pull to refresh", the refresh bar corresponds to the area displayed above the rows of the Table control during the data refresh.
- <Table>.RefreshVisible is used for example to check the display of refresh bar when the data found in the Table control is refreshed in a secondary thread. This prevents the application from freezing (the example uses this method).
- When <Table>.RefreshVisible makes the refresh bar visible, the "Pull to refresh" event of the Table control is not executed.
Note: It is possible to force execution of this event by using the ExecuteProcess function with the constant trtPullToRefresh. - To hide the refresh bar, <Table>.RefreshVisible(False) must be called as many times as <Table>.RefreshVisible(True) was run.
Componente: wd300java.dll
Esta página también está disponible para…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|