开发者

How to make a checkbox selected when searching from database

i created a form,containing fields emloyeeid,em开发者_JAVA技巧ployeename,age...,and a checkbox. When searching using employeeid ,i want to the checkbox selected/deselected according to the value saved in the database(the checkbox field in database is boolean)


Really depends on your db access approach, one example.

 checkbox1.Checked = reader.GetBoolean(ordinal);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜