AYUDA EN LÍNEA
 WINDEVWEBDEV Y WINDEV MOBILE

Este contenido se ha traducido automáticamente.  Haga clic aquí  para ver la versión en inglés.
Ayuda / WLanguage / Administrar bases de datos / HFSQL / Funciones HFSQL
  • Conditions for using HCancelDeclaration
  • HCancelDeclaration and closing the data file
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReportes y ConsultasCódigo de Usuario (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Código Navegador
WINDEV Mobile
AndroidWidget Android iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Otros
Procedimientos almacenados
Used to:
Ejemplo
// The Customer data file was declared beforehand in the analysis
// by HDeclareExternal
HClose(Customer)
HCancelDeclaration(Customer)
Sintaxis
<Result> = HCancelDeclaration([<Data file>])
<Result>: Boolean
  • True if the operation was performed,
  • False if a problem occurs. HError is used to identify the error.
<Data file>: Optional character string
Corresponds to:
  • the name of data file (defined in the analysis). If this name is not specified, HCancelDeclaration handles the last data file used.
  • the name of query or data source associated with a query (when freeing resources once HExecuteQuery or HExecuteSQLQuery has been used).
Observaciones

Conditions for using HCancelDeclaration

This function must be used ONLY when the relevant data file (or query) is not used anymore!
In the following example, HCancelDeclaration is used too soon: the content of the Table control will be completely distorted. The Table control is populated using BuildBrowsingTable in a parallel process in the background. Therefore, HCancelDeclaration will be called before the table is entirely filled, making this table unusable.
HExecuteSQLQuery("test", "select * from customer")
BuildBrowsingTable(TABLE_Table1, "test")
HCancelDeclaration("test")
Remark: The problem can also occur with a "data source" variable. A "data source" variable declared locally in a process or event (button click, procedure, method, etc.) ONLY exists while this code is run. For this reason, a "warning" is displayed when you are using this type of data source: "the data source will be destroyed at the end of this code".

HCancelDeclaration and closing the data file

To use HCancelDeclaration on a data file, this data file must be closed.
If a query, a subquery or a view uses the data file, HCancelDeclaration cannot be executed, even after calling HClose. The queries or views that are using the data file must be freed beforehand.
Componente: wd290hf.dll
Versión mínima requerida
  • Versión 9
Esta página también está disponible para…
Comentarios
How to know when table has loaded.
Is there anyway to know when the browsing table process has completed so it would be safe to do the HCancelDeclaration function?
Alan
13 01 2020

Última modificación: 06/07/2023

Señalar un error o enviar una sugerencia | Ayuda local