• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 338
  • Last Modified:

Making ComboBox Sizable

is there a way that I can make a TComboBox sizable, and also remove it's border?

<Please supply code>

Thanks
0
PPaul
Asked:
PPaul
1 Solution
 
ginsonicCommented:
listening
0
 
Lee_NoverCommented:
dunno bout that, but you check www.torry.net for compos
if you don't want the components just check the code :)
0
 
ITugayCommented:
Hi PPaul,

to remove boreder:

begin
   MakeComboFlat(Combobox1, True);
......

procedure MakeComboFlat(ABox: TWinControl; AFlat: Boolean);
var
  HR: HRgn;
  NR: HRgn;
begin
  if ABox = nil then exit;
  GetWindowRgn(ABox.Handle, HR);
  if AFlat then
    NR := CreateRectRgn(2, 2, ABox.Width - 3, ABox.Height - 3)
  else
    NR := CreateRectRgn(0, 0, ABox.Width, ABox.Height);

  SetWindowRgn(ABox.Handle, NR, True);
  DeleteObject(HR);
end;

0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now