Board index » cppbuilder » remove the border on combobox

remove the border on combobox

with a edit control is simple:

EditControl->BorderStyle = bsNone;

but with a TComboBox ? Is possible ?

I have tried with:

long l = GetWindowLong(FCombo->Handle, GWL_STYLE);
l = l & ~WS_BORDER;
SetWindowLong(FCombo->Handle, GWL_STYLE,l);

without result.

 

Re:remove the border on combobox


You need to play about with the 'BevelInner', 'BevelKind' and 'BevelOuter'.

The following seems to work:

BevelInner = bvLowered
BevelKind = bkFlat
BevelOuter = bvNone

Enjoy :)
Wayne Phillips.

Quote
"nick" <nicolazanaga...@inwind.it> wrote in message

news:3d47ecb0$1_1@dnews...
Quote
> with a edit control is simple:

> EditControl->BorderStyle = bsNone;

> but with a TComboBox ? Is possible ?

> I have tried with:

> long l = GetWindowLong(FCombo->Handle, GWL_STYLE);
> l = l & ~WS_BORDER;
> SetWindowLong(FCombo->Handle, GWL_STYLE,l);

> without result.

Other Threads