用于列出选项的 Windows 窗体控件Windows Forms Controls Used to List Options

如果你想要向用户提供可供选择的选项的列表,可以向 Windows 窗体中添加各种控件。You can add a variety of controls to a Windows Form if you want to provide users with a list of options to choose from. 具体取决于多少你想要限制用户的输入,您可以添加ListBox控件,ComboBox控件,或CheckedListBox控件。Depending on how much you want to restrict your users' input, you can add a ListBox control, a ComboBox control, or a CheckedListBox control. 使用以下链接来确定哪个控件最适合你的需求。Use the following links to determine which control best suits your needs.

本节内容In This Section

何时使用 Windows 窗体 ComboBox 而非 ListBoxWhen to Use a Windows Forms ComboBox Instead of a ListBox
建议根据需求和 Windows 窗体的限制基于列表的相应控件。Recommends an appropriate list-based control depending on the needs and restrictions of your Windows Form.

如何:访问特定于 Windows 中的项窗体 ComboBox、 ListBox 或 CheckedListBox 控件How to: Access Specific Items in a Windows Forms ComboBox, ListBox, or CheckedListBox Control
提供用于以编程方式确定列表中的项出现在给定位置的说明。Gives instructions for programmatically determining which item in a list appears in a given position.

如何:添加和删除项从 Windows 窗体 ComboBox、 ListBox 或 CheckedListBox 控件How to: Add and Remove Items from a Windows Forms ComboBox, ListBox, or CheckedListBox Control
添加或删除项的控件的项列表中提供的说明。Gives instructions for adding or removing items from a control's list of items.

如何:为 Windows 窗体 ComboBox、 ListBox 或 CheckedListBox 控件创建查找表How to: Create a Lookup Table for a Windows Forms ComboBox, ListBox, or CheckedListBox Control
指示如何显示并将窗体数据存储在有用的格式。Gives directions for displaying and storing form data in useful formats.

如何:将 Windows 窗体 ComboBox 或 ListBox 控件绑定到数据How to: Bind a Windows Forms ComboBox or ListBox Control to Data
提供有关如何将基于列表的控件绑定到数据源。Gives directions for binding a list-based control to a data source.

如何:排序的内容的 Windows 窗体 ComboBox、 ListBox 或 CheckedListBox 控件How to: Sort the Contents of a Windows Forms ComboBox, ListBox, or CheckedListBox Control
介绍如何在其数据源的列表数据进行排序。Explains how to sort list data at its data source.

参考Reference

CheckedListBox
对此类进行描述,并提供指向其所有成员的链接。Describes this class and has links to all its members.

ComboBox
对此类进行描述,并提供指向其所有成员的链接。Describes this class and has links to all its members.

ListBox
对此类进行描述,并提供指向其所有成员的链接。Describes this class and has links to all its members.

CheckedListBox 控件概述CheckedListBox Control Overview
说明此控件的本质及其主要功能和属性。Explains what this control is and its key features and properties.

ComboBox 控件概述ComboBox Control Overview
说明此控件的本质及其主要功能和属性。Explains what this control is and its key features and properties.

ListBox 控件概述ListBox Control Overview
说明此控件的本质及其主要功能和属性。Explains what this control is and its key features and properties.

在 Windows 窗体上使用的控件Controls to Use on Windows Forms
提供 Windows 窗体控件的完整列表,附带其使用情况相关信息的链接。Provides a complete list of Windows Forms controls, with links to information on their use.