PC SOFT

ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Home | Sign in | English EN
This content has been translated automatically. Click here to view the French version.
  • Windows of exceptions and errors
  • Processing exceptions through programming
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
dbgSaveDebugDump (Function)
In french: dbgSauveDumpDébogage
Saves a dump file of the application. A dump file is used to reposition "later" the debugger on the runtime information of the application when the function was called. This allows you to view the stack and the content of variables when opening the dump file generated in WINDEV, WEBDEV or WINDEV Mobile.
To read the dump file, you must:
  • Drag and Drop the ".wdump" file to the window editor or page editor (on the bar of opened documents for example).
  • directly open the ".wdump" file (on the "Home" tab, in the "General" group, expand "Open" and select "Open").
Remarks:
  • To view the dump file, the current project in the editor must be the project of the application or the project of one of the components used by the application. Only the information regarding the current project will be displayed.
  • Unlike the memory dump, the dump file is used to view the content of the memory and the content of the variables during the call to the function.
Example
// Sauve le dump de débogage dans l'audit d'exécution en cours
dbgSaveDebugDump()
// Sauve le dump de débogage dans un fichier
dbgSaveDebugDump(fExeDir() + ["\"] + "MonDump.wdump")
Syntax

Saving the dump file in the current dynamic audit

dbgSaveDebugDump()
Remark: This syntax saves the memory dump in the dynamic audit file if the audit is enabled (dbgEnableAudit). The function has no effect if the dynamic audit is not enabled. The audit can be enabled by dbgEnableAudit.

Saving the dump file in a file Hide the details

dbgSaveDebugDump(<Name of dump file>)
<Name of dump file>: Character string
Name of the file where the dump is saved. The name of the file can be built with the following elements:
[%ExeDir%]Directory of executable, always filled with the "\" character. This directory is equivalent to the result of fExeDir.
[%ExeName%]Executable name.
[%Date%]Start date of the dump file (YYYYMMDD format).
[%Time%]Start time of the dump file (HHMMSS format).
[%UserName%]Name of the current user.
[%ComputerName%]Computer name.
Versions 18 and later
[%DataDir%]
New in version 18
[%DataDir%]
[%DataDir%]
Directory of the HFSQL data files specified by the user when installing the application. This directory is equivalent to the result of fDataDir.
Versions 18 and later
[%DirUserData%]
New in version 18
[%DirUserData%]
[%DirUserData%]
Directory for the data of the current user of the current application. This directory is equivalent to the result of fDataDirUser.

If this parameter corresponds to an empty string (""):
  • The extension of the file will be ".wdump".
  • the name of the created file corresponds to: "[%UserDataDir%][%ExeName%]_[%Date%]_[%Time%]".
    For example: "C:\Users\Doc\AppData\Roaming\WINDEV Applications\MyApp\MyApp_20091023_130812.wdump".
Versions 22 and later
Caution: If you use the dynamic string construction ("Allow "[% %]" in the strings" in the "Compilation" tab of the project description), a compilation error occurs (unknown identifier). In this case, each string must be preceded by '-%'. Example:
dbgSaveDebugDump("[%RepDonneesUtilisateur%][%NomExe%]_[%Date%]_[%Heure%]")
becomes
dbgSaveDebugDump(-%"[%RepDonneesUtilisateur%][%NomExe%]_[%Date%]_[%Heure%]")
New in version 22
Caution: If you use the dynamic string construction ("Allow "[% %]" in the strings" in the "Compilation" tab of the project description), a compilation error occurs (unknown identifier). In this case, each string must be preceded by '-%'. Example:
dbgSaveDebugDump("[%RepDonneesUtilisateur%][%NomExe%]_[%Date%]_[%Heure%]")
becomes
dbgSaveDebugDump(-%"[%RepDonneesUtilisateur%][%NomExe%]_[%Date%]_[%Heure%]")
Caution: If you use the dynamic string construction ("Allow "[% %]" in the strings" in the "Compilation" tab of the project description), a compilation error occurs (unknown identifier). In this case, each string must be preceded by '-%'. Example:
dbgSaveDebugDump("[%RepDonneesUtilisateur%][%NomExe%]_[%Date%]_[%Heure%]")
becomes
dbgSaveDebugDump(-%"[%RepDonneesUtilisateur%][%NomExe%]_[%Date%]_[%Heure%]")
Remarks

Windows of exceptions and errors

The windows of exceptions and errors propose an option that is used to save a dump file when the exception or the error occurs. It is the following link:
"Save the information for the application provider (dump file)"

Processing exceptions through programming

The dbgSaveDebugDump function called from the exception handling code saves the dump of the report at the time of the exception and not the dump of the current report in the exception handling.
To save report at the time of the exception, you must call the function dbgSaveDebugDump directly from exception processing.
If you use the dbgSaveDebugDump function from an Procedure (or method) called in the exception processing, the report saved will be that of the current processing: the stack will no longer correspond to the exception.
Component: wd270vm.dll
Minimum version required
  • Version 15
This page is also available for…
Comments
Click [Add] to post a comment