![](https://www.cnblogs.com/Images/OutliningIndicators/ContractedBlock.gif)
填充ComBoBox中的内容function FullItemOfCB(aQry: TQuery; aFieldName: string; aCBObject: TComBoBox):
string; //填充ComBoBox中的内容
begin
aCBObject.Clear;
aQry.First;
while not aQry.Eof do
begin
aCBobject.Items.Add(aQry.FieldByName(aFieldName).AsString);
aQry.Next;
end;
end;
![](https://www.cnblogs.com/Images/OutliningIndicators/ContractedBlock.gif)
填充ListBox中的内容function FullItemOfLB(aQry: TQuery; aFieldName: string; aLBObject: TListBox):
string; //填充ListBox中的内容
begin
aLBObject.Clear;
aQry.First;
while not aQry.Eof do
begin
aLBObject.Items.Add(aQry.FieldByName(aFieldName).AsString);
aQry.Next;
end;
end;