PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK
New WINDEV 25 feature!
  • This lesson will teach you the following concepts
  • Questions/Answers
  • How to view the element to which the current event belongs?
  • How to print the WLanguage code displayed?
  • How to perform a "find and/or replace"?
  • What is the meaning of "+" and "-" signs in the code editor?
  • Is it possible to identify the person who wrote a code line?
  • Is it possible to find out the number of a code line?
  • Is there a way to easily get syntax or help on a WLanguage function?
  • What are the useful shortcuts in the code editor?
  • How to communicate with the user?
Lesson 2.5. Questions/Answers
This lesson will teach you the following concepts
  • Questions/Answers.
Lesson duration

Estimated time: 10 mn
Previous LessonTable of contentsNext Lesson

Questions/Answers

How to view the element to which the current event belongs?

To view the element that corresponds to the current event, on the "Code" pane, in the "Navigation" group, click "Go to element" (Ctrl + Alt + F2). The page containing the requested element is displayed.

How to print the WLanguage code displayed?

To print the current source WLanguage, click Print in the "Home" pane or press Ctrl + P.

How to perform a "find and/or replace"?

The functions for performing searches or replacements (in the code, in the interface, ...) can be accessed from the "Home" pane, in the "Find" group or in the "Find - Replace" pane (Ctrl + F) :
Find - Replace pane
Then, you have the ability to define the different characteristics of the search to perform.

What is the meaning of "+" and "-" signs in the code editor?

The code editor allows you to expand or collapse the WLanguage code. This feature is very useful if your processes use a lot of structured statements (loops, conditions, browses, ...).
To collapse a group of lines of code, on the "Display" pane, in the "Collapsible code" group, expand "Collapse" and select "Collapse all" (or press Ctrl + Shift + * (on the numeric keypad)).
Only the comments remain visible. Hovering over each comment allows you to view the associated WLanguage code in a tooltip:
WLanguage code collapsed/expanded
Press Ctrl + * (on the numeric keypad) to expand the WLanguage entire code. A click performed on the "-" or "+" symbol allows you to collapse or expand the corresponding code section.

Is it possible to identify the person who wrote a code line?

Press F6 to display information (name and creation/modification date) about each code line.

Is it possible to find out the number of a code line?

In the code editor, to show or hide the numbers of the code lines, on the "Display" pane, in the "Help for edit" group, click "Display line numbers" (shortcut: Ctrl + Shift + G).

Is there a way to easily get syntax or help on a WLanguage function?

When entering a WLanguage function in the code editor:
  • the name of each parameter is displayed in a tooltip for the code line currently in edit. For the parameter currently in edit, hovering the parameter name with the mouse is used to display the parameter details in a tooltip.
    If several syntaxes are available, it is possible to switch from one syntax to another using Ctrl + up arrow or down arrow.
  • the syntax of the WLanguage function is displayed in the status bar of the editor.
In the help, the parameters enclosed between [ and ] are optional parameters.
For WLanguage functions that require names of data files, controls, windows or reports, the assisted input is used to display the list of project elements corresponding to the parameter of the function currently typed.
Examples of assisted input for HReadFirst: the <Wizard> option is used to start a code wizard. This wizard asks you questions regarding the function use and automatically generates the corresponding code.
A help page is associated with each WLanguage function and property. This help page can be directly accessed from the editor by pressing F1 on the name of requested function or property.

What are the useful shortcuts in the code editor?

  • To display the events of a control, method, class, procedure or report block, press F2 while on the name of the desired element.
  • Ctrl + F2 is used to go back to the initial process or event.
    To move from one process/event to another, press F2 repeatedly. To go back to the initial process or event, press Ctrl + F2 the same number of times.
  • Ctrl + L deletes the current line.
  • Ctrl + D duplicates the current line (or the selected lines) on the line below.
  • Tab (tab key) and Shift + Tab are used to manage the indent for the selected lines.
  • Ctrl + / converts the selected lines into comments, Ctrl + Shift + / removes the comments (Caution: / key on the numeric keypad).
  • Ctrl + R is used to automatically re-indent the displayed code.

How to communicate with the user?

All you have to do is use an advanced dialog box. These dialog boxes are used to manage:
  • the directive questioning (Dialog): the user answers a question via the buttons containing the text of the action to perform.
  • the immediate input (Input), by allowing the user to type the requested value in the dialog box.

  • To check the different modes for communicating with the user:
    1. Open the "WD My first windows" project if necessary: on the "Home" pane, in the WINDEV home page (Ctrl + <), click "Tutorial", then "My first windows (Answer)".
    2. Open the "WIN_Dialog" window. This window presents the different dialog modes.
    3. Test this window ( Running a window test among the quick access buttons).
    4. Click the different buttons to check the different dialog modes.
      Test of dialog modes
    5. Stop the test of this window and go back to the code editor to study the code of each Button control.
Previous LessonTable of contentsNext Lesson
Minimum version required
  • Version 25
Comments
Click [Add] to post a comment