PC SOFT

WINDEV的在线文档

  • Overview of the ListView control
  • Creating the ListView control
  • Limitations for the Panorama mode
  • Vocabulary
  • Swapping
  • ListView/Looper
文档页面当前正在翻译。对于此延迟我们深表歉意。
您可以自愿地帮助我们翻译您想要的文档段落,然后只需通过以下地址与我们联系: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 of the ListView control
The ListView control is used to display a list of graphic elements (images, logo, ... ) and to select one or more elements in this list.

Several display modes are available:

  • ListView mode: The listview is expanded, which means that several listview elements are displayed in the window.
  • Standard List Box mode: The images are not displayed in the listview. Only the captions are displayed.
  • 16版本和更高版本
    WinDev Panorama mode: The images appear as if they were displayed on a curved wall.
    16新版本
    WinDev Panorama mode: The images appear as if they were displayed on a curved wall.
    WinDev Panorama mode: The images appear as if they were displayed on a curved wall.

These elements can:

  • be defined by programming.
  • come from a data file or from a query.
Note: A listview can be used to perform an automatic "Drag and Drop". See Managing Drag and Drop for more details.

Creating the ListView control
To create a ListView control:
  1. In the window editor, click(or select "Insert .. Control .. ListView") .On the "创建" pane, in the "数据" group:
    • WinDev expand "Table and list" and select "ListView".
    • WinDev expand "List" and select "ListView".
  2. Click the position where the control must be created in the window. The wizard for creating a ListView control is automatically started.
To display the characteristics of the control, select "Description" from the popup menu of the control.

16版本和更高版本
WinDev

Limitations for the Panorama mode

  • The ListView control can display up to 20 images. If the list contains more elements, the additional elements will be present but they will not be visible to the user.
  • Several features are not available: management of scrollbars, ...
16新版本
WinDev

Limitations for the Panorama mode

  • The ListView control can display up to 20 images. If the list contains more elements, the additional elements will be present but they will not be visible to the user.
  • Several features are not available: management of scrollbars, ...
WinDev

Limitations for the Panorama mode

  • The ListView control can display up to 20 images. If the list contains more elements, the additional elements will be present but they will not be visible to the user.
  • Several features are not available: management of scrollbars, ...

Vocabulary
To easily handle a listview, you must be familiar with the following vocabulary:
NameDefinition
ElementA listview is made of several elements. Each element includes an image and a caption.
Display modeA listview can be displayed:
  • in "ListView" mode: the images and captions will be displayed in the listview.
  • in "Standard list box" mode: only the captions will be displayed in the listview.
  • 16版本和更高版本
    WinDev in "Panorama" mode: the images will be displayed in the listview with a curved effect.
    16新版本
    WinDev in "Panorama" mode: the images will be displayed in the listview with a curved effect.
    WinDev in "Panorama" mode: the images will be displayed in the listview with a curved effect.
Selection barUsed to view the selected element. A specific color is used in most cases.
Browsing listviewThe listview is based on a data file or on a query. The elements of the listview correspond to the records of the data file.
Two types of browsing listviews are available:
  • Browsing listview "Loaded in memory": the content of the listview is loaded in memory then it is displayed. The access to the listview elements is faster. This mode is reserved for the data files containing less than 100 000 records.
  • Browsing listview in "Direct access (no limit)": The listview directly displays the content of the data file or query. The current record corresponds to the selected element. Each move performed in the listview involves an access to the linked file. This type of listview is reserved for the data files containing more than 100 000 records.
Memory listviewThe listview is not based on a file or on a query. The elements displayed in the listview are defined by programming.
Single-selection listviewThe user can select a single element in the list.
Multi-selection listviewThe user can select several elements at the same time in the list (via the CTRL key)
Vertical/Horizontal scrollScroll direction of the listview.
A vertical scrollbar is automatically displayed if the number of elements displayed in the list exceeds the number of visible elements.
If the size of the elements is greater than the width of the list, an horizontal scrollbar is automatically displayed.
ListView on sourceThe listview is based on a variable (global to the project, to the window or to the page, class member, ...).

Swapping
16版本和更高版本

ListView/Looper

A ListView control can be automatically changed into a Looper control:
  1. Select the ListView control to transform.
  2. Select "Control .. Swap .. Listview to Looper".On the "修改" pane, in the "转换" group, expand "重构和切换" and select "ListView to Looper".
16新版本

ListView/Looper

A ListView control can be automatically changed into a Looper control:
  1. Select the ListView control to transform.
  2. Select "Control .. Swap .. Listview to Looper".On the "修改" pane, in the "转换" group, expand "重构和切换" and select "ListView to Looper".

ListView/Looper

A ListView control can be automatically changed into a Looper control:
  1. Select the ListView control to transform.
  2. Select "Control .. Swap .. Listview to Looper".On the "修改" pane, in the "转换" group, expand "重构和切换" and select "ListView to Looper".