在使用IP的WWDBGrid时设置了某字段为CheckBox,取值为yes\no或true\false, 可是运行后怎么也显示不了钩钩呀。。怎么办????with DBGrid1.DataSource.DataSet do
begin
disablecontrols;
first;
while not eof do
begin
ADOQueryPOConf.Edit;
// fieldbyname('selected').value:=True;
if fieldbyname('selected').value then
showmessage('此行已选中');;
ADOQueryPOConf.Post;
next;
end;
enablecontrols;
end; 另外如果不赋值的话,fieldbyname('selected').value说是NULL,
请问怎样才能通过代码,设置checkbox的值,从而让画面上打勾?
不用selectrow,通过给checkbox赋值打勾
begin
disablecontrols;
first;
while not eof do
begin
ADOQueryPOConf.Edit;
// fieldbyname('selected').value:=True;
if fieldbyname('selected').value then
showmessage('此行已选中');;
ADOQueryPOConf.Post;
next;
end;
enablecontrols;
end; 另外如果不赋值的话,fieldbyname('selected').value说是NULL,
请问怎样才能通过代码,设置checkbox的值,从而让画面上打勾?
不用selectrow,通过给checkbox赋值打勾
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货