RE: The ComboBox Problems
- Posted by Derek Parnell <Derek.Parnell at SYD.RABOBANK.COM> Jun 05, 2002
- 408 views
This message is in MIME format. Since your mail reader does not understand this format, some or all of this message may not be legible. ------_=_NextPart_000_01C20CDD.FFD833A0 charset=iso-8859-1 > -----Original Message----- > From: Bernie Ryan [mailto:xotron at localnet.com] > Sent: Thursday, 6 June 2002 7:33 > To: EUforum > Subject: The ComboBox Problems > > > What should a combobox display in the edit contol > when it is displayed ? ( the list contains items ) The currently *selected* item. > ex6.exw in the win32lib shows a open list which was > changed from the original ex6.exw used combobox and > its edit control was shows a empty blue box. When you say "combobox" I assume you really mean DropDownList. This is a type of combobox in which the user can only select items that are in the list - the user cannot edit the 'editbox' portion of the combo. The "empty blue box" signifies that there is NO item currently selected. > The index returned by the combo or list box should > return a zero based index but the code adds one to it. In the Microsoft (and C) world, most array references are zero-based. However, in Euphoria and the average person's world, most array references are one-based. That is, we normally start counting a list of items by starting with "one". In win32lib, we have endeavoured to remain consistent with Euphoria's one-based referencing (NB: even Eu is not consistent in this regard considering that routine_id's start at zero). > If you click on the original ex6.exw demo without > selecting any thing the index returned is zero ? Thus when getIndex() is called, it returns a one-based number indicating the number of the list item that is selected. If it returns a zero, it means that there is NO item currently selected. > I'am trying to make my w32engin.ew compatible with the > win32lib but I want the code to work the way it works > in windows "C" code. You cannot have both. Either you have a one-based system or a zero-based system. -------- Derek. ================================================================== ================================================================== ------_=_NextPart_000_01C20CDD.FFD833A0 Content-Type: application/ms-tnef