PC SOFT

WINDEV的在线文档

  • Overview
  • Attributes and controls of a browsing Looper control
  • Attributes and controls of a browsing Looper control in WinDev or WinDev Mobile
文档页面当前正在翻译。对于此延迟我们深表歉意。
您可以自愿地帮助我们翻译您想要的文档段落,然后只需通过以下地址与我们联系: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本地访问

Overview
A browsing Looper control is a Looper control based on a data file or on a query.

Each row of the Looper control corresponds to a record of the data source.

The number of records that can be viewed is unlimited, only the visible rows of the control are loaded in memory.

17版本和更高版本
The Live Data (available in the editor) is used to easily resize the controls found in the rows.
17新版本
The Live Data (available in the editor) is used to easily resize the controls found in the rows.
The Live Data (available in the editor) is used to easily resize the controls found in the rows.

Attributes and controls of a browsing Looper control

WinDevWindows Store apps

Attributes and controls of a browsing Looper control in WinDev or WinDev Mobile

A Looper control includes controls that are repeated on each row.

When creating a browsing Looper control, a control is created for each item found in the data file or in the query.

To modify one or more characteristics of these controls (color, status, width, height, ...), all you have to do is handle these controls by programming in the "Displaying a row of the Looper control" process.

For example, the Looper control named "LOOP_MyLooper" is based on "Customer" file. This data file contains 10 items (name, address and phone number of each customer for example). When creating the Looper control, 10 controls will be automatically created: each control will be linked to an item of "Customer" file.

In order for the background color of the "EDT_CustomerName" control to change on each row, this control must be handled by programming to define the requested background color. For example:

// -- Displaying a row of LOOP_MyLooper
Subscript整数型
// Retrieve the subscript of the current row
SubscriptLOOP_MyLooper

如果是偶数Subscript)=,那么
// The background color will be red for the even rows
LOOP_MyLooperSubscript】.EDT_CustomerName..背景颜色=浅红色
否则
// The background color will be blue for the odd rows
LOOP_MyLooperSubscript】.EDT_CustomerName..背景颜色=浅蓝色
结束

Note: For compatibility with WebDev, you also have the ability to use the attributes.