PC SOFT

WINDEV的在线文档

  • Processes managed by default
  • Processes managed by WinDev and WinDev Mobile
  • Filtering the records (browsing looper only)
  • Optional processes
文档页面当前正在翻译。对于此延迟我们深表歉意。
您可以自愿地帮助我们翻译您想要的文档段落,然后只需通过以下地址与我们联系:info@cn.windev.com
产品
WinDevWebDev-服务器代码WebDev-浏览器代码WinDev Mobile报表和查询
平台
WindowsLinuxWindows MobileWindows PhoneWindows Store appsAndroidAndroid Widget iPhone/iPad
语言
JavaPHPAjax用户代码(MCU)外部语言
数据库
HFSQLHFSQL Client/Server存储过程HF 5.5OLE DBODBC本地访问

Processes associated with the Looper controls

Processes managed by default
WinDevWindows Store apps

Processes managed by WinDev and WinDev Mobile

WinDev and WinDev Mobile manage the following processes by default (in the order in which they appear in the code editor):
ProcessRuntime condition
InitializationRun when opening the window.*

Special case: Browsing looper automatically filled:
When this code is run, the looper is not filled yet. To force the looper to be filled in this code, use:
You also have the ability to filter the records with H过滤器.
End of initializationProcess found for the browsing Looper controls automatically filled:
Run once the looper was filled. This code can be used to add or modify a looper element.
Entry in the looperRun when one of the looper controls takes focus.
Exit from the looperRun when changing control (TAB key, change of control with the mouse, ...)
Whenever the looper is modifiedRun when the user modifies the content of the looper.

Enter in input in a looper rowRun when the user selects a row to perform an input in this row.

Exit from a row of the looperRun when changing row or when changing control (TAB key, change of control with the mouse, ...) from a row.

Displaying a looper rowRun when a new row must be displayed in the looper: re-display of the looper, ...

Selecting a looper rowRun when the user selects a row (without input).
This process is automatically added when the "Pull to refresh" feature was enabled ("Details" tab in the description window of the Looper control).
This process is run when a refresh gesture is detected on the Looper control.

At the end of this process, the refresh bar will be automatically hidden except if LooperRefreshVisible was called.

See Pull to Refresh on the Table and Looper controls (Android/iOS) for more details.

Process found only if an automatic deletion was defined when swiping a row ("Details" tab of the control description)

Run before the automatic deletion of the record displayed in the row. This process is used to run different tests for example. If this process returns , the deletion is not performed.

See Moves and gestures in a Looper control for more details.

Process found only if an automatic deletion was defined when swiping a row ("Details" tab of the control description)

Run after the effective deletion of the record. This process is used to redisplay the data for example.

See Moves and gestures in a Looper control for more details.

Process found only if an action was defined when swiping a row ("Details" tab of the control description)

  • Case of automatic deletion: This process is run BEFORE the "Before deleting a row" process. If this process returns , the "Before automatic deletion of a row" process is not run and the record is not deleted.
  • Case of action by programming: This process is run when the row is swiped by the user. This process is used to program the requested action.
See Moves and gestures in a Looper control for more details.
Run at the beginning of Drag/Drop for the element. This process is used to run different tests for example. If this process returns , the move is not performed.
Run at the end of Drag/Drop for the element. If this process returns , the move is not performed.
Filtering the recordsOptional code found for the browsing Looper controls filled automatically:
Run just before displaying a row. This process is used to filter the records that must be displayed in the looper control. This process is presented in details at the end of this page.

(*) By default, the "Initialization" process of each control is run according to the creation order of the controls in the window. To modify this runtime order:
  1. Select "Windows .. Edit the initialization order".On the "窗口" pane, in the "顺序" group, click "初始化".
  2. In the window that is displayed, use the arrows on the right to modify the initialization order of controls.

Filtering the records (browsing looper only)
WinDevWindows Store apps The "Filtering the records" process is run just after the display of a looper row. Therefore, it is run:
  • when initializing the looper.
  • whenever a new looper row is displayed.
This process is used to filter the records displayed in the Looper control.

To implement a filter, the "Filtering records" process must return a value:

  • to specify that the record corresponds to the filter and that it must be displayed.
  • to specify that the record does not correspond to the filter and that it must not be displayed.
  • Cancel to stop reading the data source of the looper (very rare case).
Example:
// -- Filter the records
// Displays the customers who placed orders exceeding 3000 Euros
如果Order.TotalIOT大于等于3000,那么
发送回
否则
发送回
结束

In this code, the data handled affects the record currently read by the looper. This data comes from the data file or from the query linked to the looper.

Note: In WinDev and WInDev Mobile, the "Filtering the records" process is an optional process. In WebDev, this process is proposed by default.

Optional processes
Several optional processes can be managed.

To manage an optional process, all you have to do is select it in the icon bar of the code window.

WinDev and WinDev Mobile

WebDev

You have the ability to manage:

  • the left mouse button down, up, with a double click,
  • the right mouse button down, up, ...
See the Optional processes for more details.