问题
On my dxBarManager1Bar1 a cxBarEditItem1 is a checkbox. How can I check it's state (if it's checked or not checked) ?
回答1:
For accomplishing your task, you can use the EditValue
property.
if (cxBarEditItem1.EditValue <> Null) AND (cxBarEditItem1.EditValue = True) then
ShowMessage('Checked!')
else
ShowMessage('Not Checked! (or null)');
Note that EditValue is a Variant
property which can also have Null
value.
来源:https://stackoverflow.com/questions/41296661/if-a-cxbaredititem1-is-a-checkbox-how-to-get-its-state