procedure TForm5.FormShow(Sender: TObject);
var
combEx : TComboBoxEx;
myImages : TImageList;
image : TBitmap;
begin
try
combEx := TComboBoxEx.Create(Self);
combEx.Parent := Self;
combEx.Visible := true;
combEx.ItemHeight := 20;
combEx.Style := csExDropDownList;
combEx.Align := alLeft;
combEx.DoubleBuffered := true;
image := TBitmap.Create();
myImages := TImageList.CreateSize(16, 11);
image.LoadFromFile('Name.bmp');
myImages.Add(image,nil);
image.LoadFromFile('Name2.bmp');
myImages.Add(image,nil);
combEx.Images := myImages;
combEx.ItemsEx.AddItem('1. Eintrag', 0, 0, -1, 0, nil);
combEx.ItemsEx.AddItem('2. Eintrag', 1, 1, -1, 0, nil);
combEx.ItemIndex := 0;
except on E:
Exception do begin
MessageDlg(e.Message, mtWarning, [mbOK], 0);
end;
end;
end;