Hi Michael First off, you might want to upgrade to Win32::GUI 0.0.558. The 502 is really outdated.
In short, Aldo has cautioned (on this list) a few times to beware of the -style option because its use makes you prone to omitting standard flags for the particular control, thus inadvertently causing unexpected side-effects. Use -addstyle (and it's counterpart -remstyle) instead. I found -addstyle => WS_VSCROLL | 2 to make a fully functional, standard ComboBox. Use 3 instead of 2 for read-only (Dropdown-Listbox). The CBS_ constants are not exported in GUI.pm, they are #define CBS_SIMPLE 0x0001L #define CBS_DROPDOWN 0x0002L #define CBS_DROPDOWNLIST 0x0003L There is an issue with getting the contents of the edit field of a ComboBox. It has been discussed here on the list. Find the trail "Combobox/Textfield", early April 2001, in the list archive, for the whole story. The solution was sub Combo_Anonymous { $ComboText = $Main->Combo->Text () if $_[0] == 6; } Hope that helps. Have fun, Harald | -----Original Message----- | From: Forhan, Michael [mailto:[EMAIL PROTECTED] | Sent: Friday, May 18, 2001 8:29 | To: 'perl-win32-gui-users@lists.sourceforge.net' | Subject: [perl-win32-gui-users] Dropdown Boxes | | | Hello, | I am currently working on a windows input program for an ODBC | information prompt, and am having difficulties building a | proper 'dropdown' | for listing possible DSNs. I have tried using both combo | boxes and list | boxes, and I am able to scroll through those using the | keyboard, but I would | like to be able to be more recognizable to a user by building | a dropdown | box. | I've tried adding the -style => 0x[value] for hex | values from the | 'visual basic 5.0 programmers guide to the win32 api', but | have had no luck | producing the li'l down button that is characteristic of | dropdowns. The | combobox is the closest I've come to displaying a list, as it | shows what is | available in the list underneath the text field generated by | the combo box. | | Any help that can be offered for this would be greatly | appreciated. | I have found a wealth of information about the Win32::GUI | package from this | list that would have been much more difficult to find on my own. I am | currently using Activestate ActivePerl build 522 (version | 5.005_03) and | Win32::GUI version 502. | | Thank you all, | Michael Forhan | | | | | _______________________________________________ | Perl-Win32-GUI-Users mailing list | Perl-Win32-GUI-Users@lists.sourceforge.net | http://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users |