表示Windows CheckBox。C# 复制 [System.ComponentModel.DefaultBindingProperty("CheckState")] public class CheckBox : System.Windows.Forms.ButtonBase继承 Object MarshalByRefObject Component Control ButtonBase CheckBox 属性 DefaultBindingPropertyAttribute
下表描述了 System.Windows.Forms.Appearance和 样式控件 处于不同状态的 控件CheckBox.Appearance的NormalButton。CheckBox 展开表 CheckStateAppearance.NormalAppearance.Button Checked 显示CheckBox检查标记。 控件显示为已沉没。 Unchecked CheckBox 为空。 控件将显示为凸起。 Indeterminate 显示CheckBox检查标记,并带有阴影...
获取或设置一个值,该值指示 CheckBox 是否处于选中状态。 C# 复制 [System.ComponentModel.Bindable(true)] [System.ComponentModel.SettingsBindable(true)] public bool Checked { get; set; } 属性值 Boolean 如果CheckBox 处于选定状态,则为 true;否则为 false。 默认值为 false。 注意:如果 ThreeState 属性...
CheckBox.CheckedChanged 事件参考 反馈 定义命名空间: System.Windows.Forms 程序集: System.Windows.Forms.dll Source: CheckBox.cs 当Checked 属性的值更改时发生。 C# 复制 public event EventHandler? CheckedChanged; 事件类型 EventHandler 示例 下面的代码示例演示了此成员的用法。 在此示例中,事件处理程序...
Windows.Forms 程序集: System.Windows.Forms.dll 获取或设置 CheckBox 控件上的复选框的水平和垂直对齐方式。 C# 复制 [System.ComponentModel.Bindable(true)] public System.Drawing.ContentAlignment CheckAlign { get; set; } 属性值 ContentAlignment ContentAlignment 值之一...
組件: System.Windows.Forms.dll 取得或設定核取記號在 CheckBox 控制項上的水平和垂直對齊情形。 C# 複製 [System.ComponentModel.Bindable(true)] public System.Drawing.ContentAlignment CheckAlign { get; set; } 屬性值 ContentAlignment 其中一個 ContentAlignment 值。 預設值是 MiddleLeft。 屬性 Bindable...
System.Windows.Forms.dll 绘制复选框控件。 重载 展开表 DrawCheckBox(Graphics, Rectangle, ButtonState) 在指定边界内、指定的图形表面上,绘制处于指定状态的复选框控件。 DrawCheckBox(Graphics, Int32, Int32, Int32, Int32, ButtonState) 在指定边界内、指定的图形表面上,绘制处于指定状态的复选框控件。
System.Windows.Forms.DataGridViewComboBoxEditingControl 属性 DefaultBindingPropertyAttribute 示例下面的代码示例是一个完整的应用程序,演示如何使用 Add 方法将ComboBox项添加到 、FindString方法以查找 中的ComboBox项,以及 BeginUpdate 和EndUpdate 方法来有效地将大量项添加到 。ComboBox 存储与显示文本不同的值的功能...
RadioButton and CheckBox controls have a similar function: they offer choices a user can select or clear. The difference is that multiple CheckBox controls can be selected at the same time, but option buttons are mutually exclusive.Use the Checked property to get or set the state of a Radio...
You can also use the Form class to create modal windows such as a dialog box. A special kind of form, the multiple-document interface (MDI) form, can contain other forms called MDI child forms. An MDI form is created by setting the IsMdiContainer property to true. MDI child forms are ...