首页 Delphi 正文
  • 本文约831字,阅读需4分钟
  • 1848
  • 0
举报该广告
TcxCheckComboBoxItems.Add

TcxCheckComboBoxItems.Add

摘要

TcxCheckComboBoxItems.Add

TcxCheckComboBoxItems See Also

Creates a new item and adds it to the items collection.



function Add: TcxCheckComboBoxItem;

 

Description

The Add function enables y...

TcxCheckComboBoxItems.Add

TcxCheckComboBoxItems See Also

Creates a new item and adds it to the items collection.



function Add: TcxCheckComboBoxItem;

 

Description

The Add function enables you to create a new item in the collection. Use the object returned by this function to customize the item, i.e. specify its descriptions and enabled status.



The AddCheckItem method enables you to add a new item and initialize its Description and ShortDescription properties.



The following code creates three items in a check combo box editor and sets their description and enabled status as appropriate:



//Delphi

var



I:Integer;



//...



with cxCheckComboBox1.Properties.Items do

begin

Clear();

for I := 0 to 2 do

with Add do

case I of

0:

begin

Description := 'Sources';

Enabled := False;

end;

1:

begin

Description := 'Demos';

Enabled := True;

end;

2:

begin

Description := 'Documentation';

ShortDescription := 'Docs';

Enabled := True;

end

end;

end;


📱 扫码关注公众号

公众号二维码

扫描二维码关注我们,获取更多精彩内容
实时更新 · 干货满满

收藏

扫描二维码,在手机上阅读
评论
更换验证码
友情链接