ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / WLanguage functions / Standard functions / Windows functions / Miscellaneous WINDEV functions
  • Using TraceBuild in the multilingual applications
  • Use conditions according to the platforms
  • Trace window
  • Context menu of the trace window
  • Special case
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
Displays a customizable message in the trace window opened in parallel with the current window.
Remark: Like Trace, TraceBuild can be used in the development phase to check that the program is running correctly. In the editor, the "Debugger trace" pane displays the information found in the trace window as well as the full text of errors that occurred.
Example
// Display an error message in the trace window
TraceBuild("The customer code %1 does not exist.", nCustomerCode)
Syntax
TraceBuild(<Initial string> [, <Parameter 1> [... [, <Parameter N>]]])
<Initial string>: Character string
Character string to display. This string contains optional parameters (%1 to %n). To display the % character, this character must be typed twice (%%).
<Parameter 1>: Optional character string
First parameter that will be inserted into the formatted character string.
<Parameter 1> will replace the %1 character, <Parameter 2> will replace the %2 character, etc.
The number of specified parameters must be equal to or greater than the number of parameters used in <Initial string>.
If <Initial string> contains more parameters, the additional parameters will be replaced with empty strings.
<Parameter N>: Optional character string
Nth parameter that will be inserted into the formatted character string.
<Parameter 1> will replace the %1 character, <Parameter 2> will replace the %2 character, etc.
The number of specified parameters must be equal to or greater than the number of parameters used in <Initial string>.
If <Initial string> contains more parameters, the additional parameters will be replaced with empty strings.
Remarks

Using TraceBuild in the multilingual applications

In a multilingual application, TraceBuild can be used to simplify the translation process:
  • the translator translates the message by using the "%1", "%2" characters, ... at the relevant location according to the language.
  • the optional characters can be replaced in all the supported languages.

Use conditions according to the platforms

Linux TraceBuild can be used to display the requested information in a file only. By default, this file is created in the UNIX temporary directory and is named "Trace_<Project>.txt".
PHP The information of TraceBuild is displayed at the beginning of the HTML page returned.
AndroidAndroid Widget TraceBuild saves the requested information only in the application log (at runtime or in emulator mode). This log can be viewed when the device is connected via USB or when using the emulator from the DDMS application provided with the Android SDK.
WEBDEV - Server code In AWP mode, TraceBuild is used to display the requested information in a file only (trFile constant used with TraceStart).
iPhone/iPadApple Watch TraceBuild displays requested information in the Xcode standard output window.
WINDEVWEBDEV - Server code

Trace window

  • The trace window opens automatically the first time TraceBuild is called (TraceStart is executed automatically). By default, this window is opened in the upper-left corner of the screen.
  • The operating mode of TraceBuild is equivalent to InfoBuild but the display is performed in a parallel window, without waiting for user validation.
  • WEBDEV - Server code The trace window displayed from a Browser code is different from the one displayed from a Server code. Therefore, two different trace windows can be opened at the same time.
WINDEVWEBDEV - Server code

Context menu of the trace window

The context menu of the Trace window allows you to:
  • copy/cut/paste the content of trace window.
  • save the content of the trace window in a text file.
    Caution: This option is available only if the wdxxxstd.dll library is on the end-user computer.
  • clear the contents of the trace window.
  • open the trace window on top of all the other windows (including the windows from the other applications).
  • save the size and position of the trace window when it is closed. When this window is displayed again, it will keep the size and position saved.
  • display an horizontal scrollbar.
  • display special characters in gray or use them directly: EOT, TAB, etc. Therefore, the "Carriage Return" (CR) characters found correspond to "<\r><\n>".
    Remark: This option will be taken into account from the next line of information displayed.
WEBDEV - Server code

Special case

PageDisplay and PageRefresh cannot be used after TraceBuild.
PHP If PageDisplay and PageRefresh are used, a warning message will be displayed by the PHP engine.
Component: wd290vm.dll
Minimum version required
  • Version 21
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 05/26/2022

Send a report | Local help