ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / Developing an application or website / Test
  • Overview
  • Configuring the remote computer
  • Configuring WDDebug
  • Running and debugging the executable on a remote computer
  • Debugging an executable that is already run on a remote computer
  • Starting the debugger and stopping the test
  • Starting the debugger
  • Stopping the test
  • Advanced setting of debugging ports
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
Overview
WINDEV includes different options to test and debug a project directly on the development computer (see Testing and debugging a WINDEV executable on the development computer). However, in some cases, you may have to debug directly on the end-user computer (connected over the network or via the Internet).
You can, for example, debug an application running in Taiwan from your office in Paris. The debugging is performed remotely, directly on the user configuration.
Two features are available:
  • Running and debugging the executable on a remote computer
  • Debugging an application currently running on a remote computer.
For these two features, a specific configuration of the remote computer is required.
Remark: To debug a WINDEV application remotely, it must include the wd300cpl.dll library in its framework.
Configuring the remote computer
To debug a WINDEV application on a remote computer, you must:
  • open the ports 27270 and 27280 if a firewall is used. Indeed, the communication between the development computer and the end-user computer is done via sockets. These ports can be customized. See "Advanced setting of debugging ports" in this page.
  • install and start WDDebug on the end-user computer. WDDebug can be supplied with the application (application available in the additional modules when creating the setup).
    Remark: on a 64-bit computer, the WDDebug64 application must be started.
Remarks:
  • WDDebug (32-bit version and 64-bit version) is an application that can be supplied separately. An installation package is available in the "Install\WDDebug" subdirectory of the WINDEV installation directory (WXSaaSPACKWDDEBUG.exe). Caution: WDDebug can only be used on the computers running Windows 2000 or later.
  • On a TSE session, WDDebug does not list the executables of the other sessions available on the computer. You cannot trace an executable started on the console from a TSE session on the computer.
  • To start WDDebug on the development computer:
    • the 32-bit version (WDDebug.exe) is available in the "\Programs" subdirectory of the WINDEV installation directory.
    • the 64-bit version (WDDebug64.exe) is available in the "\Programs\Framework\Win64x86" subdirectory of the WINDEV installation directory.
  • WDDebug64 must be run in "Administrator" mode if the executable to debug is in UAC mode.

Configuring WDDebug

To debug a WINDEV application on a remote computer, WDDebug must be configured by the end user:
  • to debug a running application or service, the "Allow remote debugging of running applications and services" option must be checked. The list of WINDEV applications currently run is displayed. The application to debug must be selected from this list.
  • the "Allow starting and debugging an application remotely" option allows launching and debugging the application remotely. In this case, the full name of the application as well as its command line must be specified (if it exists).
  • the "Allow restarting the application" button sends the details of the running application in the parameters to allow starting the application. It is often the case that the developer needs to restart the application to identify and fix the bug.
  • the "Allow starting and debugging a service remotely" option allows starting and debugging the service remotely.
Caution: You cannot debug several executables or services simultaneously on the same machine from several remote computers (for example, two developers who try to debug two different applications at the same time on the same remote computer).
Running and debugging the executable on a remote computer
To run and debug an executable on a remote computer:
  1. Open the relevant project in WINDEV.
  2. Contact the user in order to configure his computer.
  3. On the "Project" tab, in the "Test mode" group, expand "Test mode", go to "Remotely", and select "Run".
  4. In the window that is displayed, enter the name or IP address of the remote computer and click the "Refresh" button. The name of the application to debug is displayed. This name corresponds to the application specified by the end user.
  5. Validate.
  6. The application is started in debug mode on the user computer. The user can handle the application while you can follow the code run via the debugger (by including breakpoints in the sections of code where the problems occur).
Remark: Therefore, the code of the current project in the editor and the code of the executable can become out-of-sync: the out-of-sync code is highlighted in pink during the debug operation.
Debugging an executable that is already run on a remote computer
To debug an executable that is already run on a remote computer:
  1. Open the relevant project in WINDEV.
  2. Contact the user in order to configure his computer.
  3. On the "Project" tab, in the "Test mode" group, expand "Test mode", go to "Remotely", and select "Attach to a running executable".
  4. In the window that is displayed, enter the name or IP address of the remote computer and click the "Refresh" button. The list of applications available on the remote computer is displayed.
  5. Select the desired application and validate.
  6. The application is in debugging mode.
Starting the debugger and stopping the test

Starting the debugger

To start the debugger while running the test of the executable, use the editor:
  • In the "Code" tab, "Debugger" option, click "Pause" ().
  • A breakpoint can also be included in the code editor in front of the desired line of code. The debugger will be automatically displayed when the corresponding line is run.

Stopping the test

There are multiple methods to stop the test:
  • 1st method: Close the application being tested. WINDEV goes back to editor that was open when the test was started.
  • 2nd method: In the editor, stop the debugger ( or Shift + F5).
Advanced setting of debugging ports
If you do not want to use the debugging ports proposed by default, you have the ability to configure the debugging ports in the registry.
The ports must be configured on the development computer and on the debugging computer.
On the development computer: In the "HKEY_CURRENT_USER\SOFTWARE\PC SOFT\WINDEV\30.0\Common" registry, create the following "DWORD 32 Bits" value: "DBG_Port_COM". This value contains the number of the communication port on the server.
On the computer where the debug operation must be performed:
  1. Create the "HKEY_CURRENT_USER\SOFTWARE\PC SOFT\WDDEBUG\30.0" key if necessary.
  2. In the "HKEY_CURRENT_USER\SOFTWARE\PC SOFT\WDDEBUG\30.0" registry, create the following "DWORD 32 Bits" value: "DBG_Port_COM". This value contains the number of the communication port on the server. It must be identical to the value specified on the development computer.
  3. In the "HKEY_CURRENT_USER\SOFTWARE\PC SOFT\WDDEBUG\30.0" registry, create the following "DWORD 32 Bits" value: "DBG_Port_DBG". This value contains the number of the debugging port.
    This port must be allowed in the firewall of the client computer.
Note: These parameters are taken into account when starting WDDebug.
Minimum version required
  • Version 12
Comments
Click [Add] to post a comment

Last update: 09/08/2023

Send a report | Local help