TheSwamp

Code Red => Visual DCL Programming => AutoLISP (Vanilla / Visual) => OpenDCL => Topic started by: Guest on June 08, 2007, 02:04:40 PM

Title: Show the first item in a combobox
Post by: Guest on June 08, 2007, 02:04:40 PM
I've got two comboboxes on a form.  When I change the value of one, the other is populated.  Now, when the second combobox is populated, how can I get it to show the top item?  I just get a populated combobox with a blank top entry.

I've been messing around with this but it doesn't seem to work.

Code: [Select]
   (Odcl_ComboBox_AddString MY-BLOX_Form1_cboCats "===============")
   (Odcl_ComboBox_AddString MY-BLOX_Form1_cboCats "Miscellaneous")
   (Odcl_ComboBox_SetTopIndex MY-Blox_Form1_cboCats 1)

Should I be using something other than the SetTopIndex function?
Title: Re: Show the first item in a combobox
Post by: LE on June 08, 2007, 02:21:57 PM
I remember using: Odcl_ComboBox_SetCurSel

I need to go back to my odcl code, and see what I did, and would try to post something... useful maybe.
Title: Re: Show the first item in a combobox
Post by: Guest on June 08, 2007, 02:27:50 PM
Ahhh.... that was it.  Thanks!