在组合框的ondropdown事件输入下列代码procedure TMainform.ComboBox2DropDown(Sender: TObject);
begin
ComboBox2.Items.BeginUpdate ;
ComboBox2.items.Clear;
ComboBox2.Style:=true;
ComboBox2.Items:=screen.Fonts ;
ComboBox2.Items.EndUpdate ;
end;
在执行到ComboBox2.Style:=true;为出错
这是错误信息:
[Error] ListForm.pas(38): Incompatible types: 'TComboBoxStyle' and 'Boolean'
[Fatal Error] TListForm.dpr(5): Could not compile used unit 'ListForm.pas'