Thanks Borislav. I have made a work-around in the meantime and will investigate further your solution. Thanks.
>>>>>>>>>>Hi All,
>>>>>>>>>>
>>>>>>>>>>Forgotten - is there a way to set the max width of the dropdown list of a combobox?
>>>>>>>>>
>>>>>>>>>ColumnWidths
>>>>>>>>
>>>>>>>>Hi Borislav, i tried that but it didnt work. My row source is wide and extends beyond my ColumnWidths value. Do I need to set something else?
>>>>>>>
>>>>>>>How many columns you have and what width you want :-)
>>>>>>
>>>>>>1 column, 300 pixels which is the same as the combobox itself.
>>>>>
>>>>>What happens when you set ColumnWidths to 300?
>>>>
>>>>The same as if I leave it empty - the dropdown list extends far to the right (reflecting the underlying 120 character field to which it is bound).
>>>
>>>You want it smaller or wider?
>>>BTW you should set Columns to 1 also :-)
>>
>>I would like the dropdown area to be the same width as the combobox itself i.e. 300 pixels.
>
>
>Christian has the answer:
>
>oForm = CREATEOBJECT("form1")
>oForm.Show(1)
>
>
>DEFINE CLASS form1 AS form
>
>
> DoCreate = .T.
> Caption = "Form1"
> Name = "Form1"
>
>
> ADD OBJECT combo1 AS combobox WITH ;
> Height = 24, ;
> Left = 9, ;
> Top = 15, ;
> Width = 294, ;
> Name = "Combo1"
>
>
> PROCEDURE Init
> thisform.Combo1.RowSourceType= 6
> thisform.Combo1.RowSource = "crsTest.Fld1"
> thisform.Combo1.ColumnCount = 2
> thisform.Combo1.ColumnLines = .f.
> thisform.Combo1.ColumnWidths = TRANSFORM(thisform.Combo1.Width-50)+",0"
> ENDPROC
>
>
> PROCEDURE Load
> CREATE CURSOR crsTest (Fld1 C(120))
> FOR lnFor = 1 TO 20
> INSERT INTO crsTest VALUES(REPLICATE("A",lnFor))
> NEXT
> ENDPROC
>
>
>ENDDEFINE
>*
>*-- EndDefine: form1
>**************************************************
>
In the End, we will remember not the words of our enemies, but the silence of our friends - Martin Luther King, Jr.