ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Attention : This is version 27 of this documentation page. This feature may have been changed or removed in a higher version.
Help / WLanguage / Managing databases / HFSQL functions / HFSQL functions
  • Opening a remote analysis from an application associated (or not) with an analysis
  • Opening an analysis this is already opened
  • Closing the connection
  • HFSQL context
  • Default user
  • Version of analyses opened with HConnectRemoteAccess
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
HConnectRemoteAccess (Function)
In french: HConnecteAccèsDistant
ODBCNot available with this kind of connection
Opens an analysis in HFSQL Classic format via a remote access (this function is equivalent to the second syntax of HOpenAnalysis). This allows you to access the data files described in the analysis as well as the structure of these data files. A specific configuration is required on the server and on the client computer. For more details, see Remote access with HFSQL.
HConnectRemoteAccess is used to handle data files via Internet: this operation is transparent to the user.
Caution: When opening a "remote" analysis, some HFSQL functions are not run locally anymore: these functions are sent to the DLL for managing the remote HFSQL functions via the remote access module of wdxxxcom.dll. The only change (from a programming point of view) for an application that uses the remote access lies in the analysis opening.
Remark: To open a remote analysis, a specific configuration is required for the server and for the client computer. For more details, see Remote access with HFSQL.
// Open the SALESMGT analysis via a remote access
IF HConnectRemoteAccess("192.168.1.1", "User", "UserPassword", ...
"C:\SALESMGT\SALESMGT.WDD", "SalesMgtPassword") = False THEN
Error("Unable to open the analysis on the server." + CR + ...
"Error found: " + HErrorInfo())
END
Syntax
<Result> = HConnectRemoteAccess(<Server> [, <User> [, <User password> [, <Path of .WDD> [, <Analysis password>]]]])
<Result>: Boolean
  • True if the analysis was opened,
  • False otherwise. HErrorInfo returns more details about the problem (see the Notes).
<Server>: Character string
IP address or DNS name of server.
Reminder: An IP address is a character string containing the "Internet Protocol" address of the computer in the xxx.xxx.xxx.xxx format.
<User>: Optional character string
Name of user (for accessing the data).
If this parameter is not specified, the default username will be used (ANONYMOUS).
<User password>: Optional character string
Password associated with the username.
If this parameter is not specified, the default user password will be used (HYPERFILE).
<Path of .WDD>: Optional character string
Full path of ".WDD" file of analysis. This file contains the description of analysis to open.
If only the drive and name of analysis are specified: the analysis is sought in the current directory of the specified drive.
If neither the drive, nor the analysis path are specified, the analysis is sought in the current directory of the current disk.
If this parameter is not specified, the analysis associated with the current application is opened.
<Analysis password>: Optional character string
Analysis password, defined in the data model editor.
Remarks

Opening a remote analysis from an application associated (or not) with an analysis

The table below presents the different cases for using HConnectRemoteAccess:
Application associated with an analysisApplication not associated with an analysis
Opening the analysis locally (on the deployment server)Automatic opening when the application is startedOpening performed by HOpenAnalysis (the analysis to open must be specified)
Opening the analysis on another serverOpening performed by HConnectRemoteAccess (there is no need to specify the name and path of analysis to open)Opening performed by HConnectRemoteAccess (the analysis to open must be specified)
Result of HConnectRemoteAccessFalse:
  • if the analysis associated with the application does not exist on the server.
  • if the specified analysis does not exist on the server.
In all the cases, the application keeps working with the current analysis.
False if the specified analysis does not exist on the server.
The next access to the database will generate a WLanguage error.
True:
  • if the analysis associated with the application exists on the server and if it is valid.
  • if the specified analysis exists on the server and if it is valid.
In all the cases, the analysis is opened on the server.
True if the specified analysis exists on the server and if it is valid.
The analysis is opened on the server.

Remark: The analysis opened by HConnectRemoteAccess is searched:
  • first, in the main library of the application according to its full physical name.
  • then, on the current disk.

Opening an analysis this is already opened

If HConnectRemoteAccess opens an already open analysis on the server, this function has no effect.

Closing the connection

To close the connection to the remote access, use HCloseAnalysis.
To temporarily disable the remote access, use HSetRemoteAccess.

HFSQL context

Caution: When using HConnectRemoteAccess, the current HFSQL context is automatically reinitalized. The following operations are automatically performed:
  • Closing the current analysis.
  • 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.

Default user

The default user (name: ANONYMOUS and password: HYPERFILE) is supported by the remote access server provided with WINDEV (WDRPCServer).
If you are using another remote access server, a default user must be added into the WdRpcSrv.ini file. This file contains the connection rights granted to the users. This file is a text file that is found in the same directory as the RPC server. It must contain a "password" section in which each entry point is a user name.
For more details, see Remote access with HFSQL.
WINDEVWEBDEV - Server codeReports and QueriesWindowsUser code (UMC)AjaxHyper File 5.5

Version of analyses opened with HConnectRemoteAccess

HConnectRemoteAccess cannot be used to open the analyses in WINDEV 5.5 or WEBDEV 1.5 format (and earlier). Only the analyses in WINDEV/WEBDEV 9 format (and later) can be opened.
Business / UI classification: Business Logic
Component: wd270hf.dll
Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 05/26/2022

Send a report | Local help