当前位置:网站首页>C#应用程序界面开发基础——窗体控制(4)——选择类控件
C#应用程序界面开发基础——窗体控制(4)——选择类控件
2022-07-03 01:03:00 【DXB2021】
选择类控件
选择类控件有下拉组合框(ComboBox)控件、复选框(CheckBox)控件、单选按钮(RadioButton)控件、数值选择(NumreicUpDown)控件和列表(ListBox)控件。
1、下拉组合框控件
下拉组合框控件被称为下拉组合框控件,是由System.Windows.Forms.ComboBox类提供的,主要作用是将一个集合数据以组合框的形式显示给用户,当用户单击时将以下拉框显示给用户供用户从中选择一项。
1、创建拉下框并添加内容
2、选中下拉组合框中可编辑部分的所有文本
2、复选框控件
复选框控件,允许用户选择和清除关联选项。与单选按钮不同的是,复选框无论是处于同一个容器中还是在不同的容器中,都是允许多选的。
判断复选框
实现CheckBox控件的多项选择
3、单选按钮控件
单选按钮控件,当与其它单选按钮成对出现时,允许用户从一组选项中选择单个选项。也就是说,当同一个容器中存在两个以上的单选按钮时,只能有一个被选中。但不在同一个容器中的几组单选按钮彼此不关联,是可以有多个被选中的。
使用RadioButton控件完成一道 选择题。
4、数值选择控件
数值选择控件又称为数值选择控件,是一个显示和输入数值的控件,控件提供了一对上下箭头,主要作用是将一个数按一定的值进行增加或减少。它主要有四个常用的属性:
(1)Increment属性表示每次单击按钮时增加或者减少的量。
(2)Maximum属性表示最大值。
(3)Minumum属性表示最小值。
(4)Value属性表示当前值。
5、列表控件
列表控件又称列表框,它显示一个项目列表供用户选择。在列表框中,用户一次可以选择一项,也可以选择多项。
1、在ListBox控件中添加和移除项
2、在列表框中选择多项
边栏推荐
- Usage of using clause in kingbases alter table
- Delete duplicate elements in the ordered linked list -ii
- matlab 多普勒效应产生振动信号和处理
- The meaning of wildcard, patsubst and notdir in makefile
- R language ggplot2 visualization: use ggplot2 to display dataframe data that are all classified variables in the form of thermal diagram, and customize the legend color legend of factor
- 关于Fibonacci数列
- Androd Gradle 对其使用模块依赖的替换
- Excel calculates the difference between time and date and converts it into minutes
- d,ldc构建共享库
- 按键精灵打怪学习-前台和内网发送后台验证码
猜你喜欢

Top ten regular spot trading platforms 2022

MySQL --- 数据库查询 - 条件查询

Excel calculates the difference between time and date and converts it into minutes

Basis of information entropy

Detailed explanation of Q-learning examples of reinforcement learning

Esp32 simple speed message test of ros2 (limit frequency)

Embrace the safety concept of platform delivery

Data analysis, thinking, law breaking and professional knowledge -- analysis method (I)

有向图的强连通分量

每日一题之干草堆的移动
随机推荐
R language uses coin package to apply permutation tests to independence problems (permutation tests, whether response variables are independent of groups, are two numerical variables independent, and
Several cases of recursive processing organization
leetcode 6103 — 从树中删除边的最小分数
[day 29] given an integer, please find its factor number
[system analyst's road] Chapter V double disk software engineering (development model development method)
How wide does the dual inline for bread board need?
excel去除小数点后面的数据,将数字取整
Excel removes the data after the decimal point and rounds the number
MySQL - database query - condition query
Androd Gradle 对其使用模块依赖的替换
Matlab Doppler effect produces vibration signal and processing
What operations need attention in the spot gold investment market?
Mongodb common commands of mongodb series
不登陆或者登录解决oracle数据库账号被锁定。
MySQL foundation 07-dcl
【无标题】
Leetcode 6103 - minimum fraction to delete an edge from the tree
强化学习 Q-learning 实例详解
按键精灵打怪学习-自动回城路线的判断
[androd] module dependency replacement of gradle's usage skills