ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / Managing databases / HFSQL / HFSQL functions
  • Starting an application associated with an analysis
  • Starting an application not associated with an analysis
  • Opening an analysis that is already open
  • Analysis version supported by HOpenAnalysis
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Opens an analysis in HFSQL Classic format. This allows you to access the data files defined in the analysis as well as their structure.
Caution: Only one analysis can be opened with HOpenAnalysis.
  • If an analysis was already open when the function was called, it is automatically closed along with the associated data files.
  • To open several analyses simultaneously, open the main analysis with HOpenAnalysis and additional analyses with HOpenComplementaryAnalysis.
Caution: When using HOpenAnalysis, the current HFSQL context is automatically reinitalized. The following operations are automatically performed:
  • All opened data files are closed.
  • All existing HFSQL views are deleted.
  • All existing queries are deleted.
  • All the declarations made with HDeclareExternal and HDescribeFile are deleted.
Example
// Open the SALESMGT analysis
HOpenAnalysis("C:\SALESMGT\SALESMGT.WDD", "Password")
Syntax
<Result> = HOpenAnalysis(<WDD file path> [, <Password>])
<Result>: Boolean
  • True if the analysis was opened,
  • False otherwise. HError returns more details about the problem.
<WDD file path>: Character string
Full path of the ".WDD" file of the analysis. This file contains the description of the analysis to be opened.
WINDEVWEBDEV - Server code If only the drive and the name of the analysis are specified, the analysis is searched for in the current directory of the specified drive.
If neither the drive, nor the analysis path are specified, the analysis is searched for in the current directory of the current disk.
The <Unit>:<Analysis name> syntax is used to search for the analysis in the current directory of the specified drive.
<Password>: Optional character string
  • Analysis password, defined in the data model editor.
  • Empty string ("") if no password is associated with the analysis.
Remarks

Starting an application associated with an analysis

  • When starting an application, the analysis associated with this application is automatically opened. The analysis is searched for in the main library of the application, then in the directory of the application.
    To make sure the analysis is found, we advise you to include the analysis in the main library of the application.
  • If HOpenAnalysis is called by an application associated with an analysis, this function:
    • has no effect if the path of the specified analysis corresponds to the path of the analysis associated with the application.
    • returns False if the path of the specified analysis does not exist. In this case, the application keeps working with the current analysis.
    • opens the analysis and returns True if the specified analysis exists and if it is valid.

Starting an application not associated with an analysis

When an application that is not associated with an analysis is started, no analysis is automatically opened. In this case, you need to use HOpenAnalysis.
The analysis opened by HOpenAnalysis is searched:
  • first, in the main library of the application according to its full physical name.
  • then, on the current disk.

Opening an analysis that is already open

If the analysis you are trying to open with HOpenAnalysis is already open, HOpenAnalysis has no effect.

Analysis version supported by HOpenAnalysis

HOpenAnalysis cannot be used to open Hyper File 5.5 analyses (and earlier versions). Only HFSQL Classic analyses can be opened.
To use HOpenAnalysis on Hyper File 5.5 files, you must use the " .WDD" file in an HFSQL Classic analysis containing files Hyper File 5.5 files. In this case, the ".WDD" file of the source WINDEV 5.5 analysis must necessarily be found in the directory of the executable.
You can also use HDeclare to directly handle a Hyper File 5.5 file.
Business / UI classification: Business Logic
Component: wd300hf.dll
Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 06/04/2024

Send a report | Local help