使用单选按钮之类的复选框 [英] using check box like radio button

查看:68
本文介绍了使用单选按钮之类的复选框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我要使用复选框

例如单选按钮....

i want to use check box

like radio button ....

推荐答案

使用单选按钮作为单选按钮.这样,您可以避免混淆用户.

—SA
Use radio button as radio button. This way, you could avoid confusing the users.

—SA


如果您引用的是设计,则此处为代码

如果您有两个复选框(Chk1,Chk2),则代码如下

在chk1上单击事件
If you are referring the design then here is code

if you have two check boxes (Chk1,Chk2) then code like this

on chk1 click event
chk2.Checked=false;



在chk2上单击事件



on chk2 click event

chk1.Checked=false;


对于C#Win App
使用CheckedListBox并将Property SelectionMode设置为One
For C# Win App
Use CheckedListBox and set Property SelectionMode as One


这篇关于使用单选按钮之类的复选框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆