Thanks, that worked great! I wasn't aware of the -addstyle and -remstyle options, and part of that may be the documentation that I've found so far regarding Win32::GUI ( http://velocity.activestate.com/code/cpan/w/wi/Win32-GUI.html/docs/new.html ), I thank you for bringing that to my attention.
I have had problems installing version 558 of Win32::GUI on my machine, most notably when I try to compile (with nmake from ms) I get: NMAKE : fatal error U1077: 'C:\PERL\BIN \PERL.EXE' : return code '0xff' Stop. and unfortunately, I'm not great with compilation. I may try running the ppm for 558, but as its listed only for perl 5.6, I fear I might run into problems. (guess there is nearly no harm in trying). Thanks again for all your help! Michael Forhan, [EMAIL PROTECTED] -----Original Message----- From: Piske, Harald [mailto:[EMAIL PROTECTED] Sent: Friday, May 18, 2001 9:25 AM To: 'perl-win32-gui-users@lists.sourceforge.net' Subject: RE: [perl-win32-gui-users] Dropdown Boxes 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 | _______________________________________________ Perl-Win32-GUI-Users mailing list Perl-Win32-GUI-Users@lists.sourceforge.net http://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users