You can subscribe to this list here.
2001 |
Jan
(226) |
Feb
(139) |
Mar
(156) |
Apr
(95) |
May
(181) |
Jun
(166) |
Jul
(80) |
Aug
(59) |
Sep
(69) |
Oct
(83) |
Nov
(142) |
Dec
(33) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(42) |
Feb
(91) |
Mar
(76) |
Apr
(113) |
May
(67) |
Jun
(68) |
Jul
(37) |
Aug
(41) |
Sep
(16) |
Oct
(135) |
Nov
(51) |
Dec
(21) |
2003 |
Jan
(37) |
Feb
(36) |
Mar
(37) |
Apr
(103) |
May
(68) |
Jun
(70) |
Jul
(77) |
Aug
(12) |
Sep
(9) |
Oct
(53) |
Nov
(88) |
Dec
(63) |
2004 |
Jan
(263) |
Feb
(106) |
Mar
(36) |
Apr
(21) |
May
(21) |
Jun
(34) |
Jul
(33) |
Aug
(34) |
Sep
(35) |
Oct
(21) |
Nov
(43) |
Dec
(63) |
2005 |
Jan
(28) |
Feb
(42) |
Mar
(29) |
Apr
(14) |
May
(41) |
Jun
(20) |
Jul
(65) |
Aug
(136) |
Sep
(41) |
Oct
(74) |
Nov
(34) |
Dec
(94) |
2006 |
Jan
(85) |
Feb
(94) |
Mar
(68) |
Apr
(103) |
May
(66) |
Jun
(51) |
Jul
(24) |
Aug
(56) |
Sep
(57) |
Oct
(85) |
Nov
(73) |
Dec
(68) |
2007 |
Jan
(59) |
Feb
(32) |
Mar
(13) |
Apr
(32) |
May
(36) |
Jun
(36) |
Jul
(64) |
Aug
(35) |
Sep
(19) |
Oct
(10) |
Nov
(13) |
Dec
(20) |
2008 |
Jan
(26) |
Feb
(41) |
Mar
(19) |
Apr
(24) |
May
(16) |
Jun
(33) |
Jul
(34) |
Aug
(4) |
Sep
(11) |
Oct
|
Nov
(26) |
Dec
(23) |
2009 |
Jan
(5) |
Feb
(2) |
Mar
(21) |
Apr
(16) |
May
(13) |
Jun
(6) |
Jul
(34) |
Aug
(2) |
Sep
(1) |
Oct
(7) |
Nov
(5) |
Dec
(24) |
2010 |
Jan
(3) |
Feb
(5) |
Mar
(6) |
Apr
(6) |
May
(14) |
Jun
(6) |
Jul
(1) |
Aug
(12) |
Sep
(10) |
Oct
(9) |
Nov
|
Dec
(2) |
2011 |
Jan
(4) |
Feb
(5) |
Mar
(30) |
Apr
(1) |
May
(2) |
Jun
(5) |
Jul
(3) |
Aug
(2) |
Sep
(3) |
Oct
|
Nov
(6) |
Dec
|
2012 |
Jan
|
Feb
(10) |
Mar
|
Apr
|
May
(1) |
Jun
(3) |
Jul
(1) |
Aug
|
Sep
(2) |
Oct
|
Nov
(2) |
Dec
(4) |
2013 |
Jan
(5) |
Feb
(3) |
Mar
|
Apr
(3) |
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2014 |
Jan
(2) |
Feb
|
Mar
|
Apr
(1) |
May
(3) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(9) |
Nov
(7) |
Dec
|
2015 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(4) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2017 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
(5) |
Dec
|
2019 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
|
From: Veli-Pekka <vt...@ma...> - 2007-07-27 13:07:20
|
Hi Robert, First of all, good to hear you are working on a TK-like layout manager. I'm looking forward to its release. Although another great way to do GUis would be to design them with the Visual Studio tools and then load the resources in Win32::GUI. Is that supported, i.e. can I load plain Win32 dialogs or menus and have Perl do the event handling? I suppose not. Robert May wrote: > I'm actually of the opinion that we should be moving more of the code > back into perl from XS. <snip> > The biggest advantage of moving more of the code into perl would be > that people who are not Win32 API gurus can see how things are done, > and modify things that they need to. Well said I second that request. I've lately learned that if I don't get something in the API docs or want to learn how some processing is done, I can always check the source with ease. That's great. This reminds me of some misc questions I have about controls: Is the Win32::GUI::MakeMenu() function documented as used by the Notepad example in 1.03? I don't see it mentioned anywhere. What's the difference between track bar and slider? i used the slider and it works great. However, my screen reader and MSDN calls the control a track bar. Most people I know talk casualy about sliderse or faders if it is a mixer. Also I had two initial problems with the slider control. I failed to specify a size and was slightly disappointed that sliders cannot bundle a label with the control like check boxes can. Chek boxes don't even need their size specified. Would be nice if sliders had a default size, too, though maybe this is a mishap in the underlying Win32 APi. On a more general note, how do I specify the tab order in a dialog? It seems to me the tab order is analogous to the insertion order which is mostly OK but not always. Last but not least, how do I indicate that a group of radio buttons forms a radio control? Oh and before I forget: I have an unusual keybord interface where I'd like a push button to be pushed down while a key is hehld down and released on key up. How would I go about this, are there key up / down events for buttons and how do I programmatically push a button in stead of clicking it which means push and release? Can I ignore keyboard messages that are a result of Windows's key repeat when a key is held down? -- With kind regards Veli-Pekka Tätilä (vt...@ma...) Accessibility, game music, synthesizers and programming: http://www.student.oulu.fi/~vtatila |
From: Veli-Pekka <vt...@ma...> - 2007-07-27 08:32:08
|
Robert May wrote: > > but as a quick > > workaround in my apps I store the perl objects in the window hash: > It's better practice to use the UserData() or ClassData() methods to > store data with a window - that's the documented interface - Yup I've noticed, it can be quite useful. Here's a real world example in my first major Win32::GUI project: in my little Perl drum machine I had 16 checkboxes without labels and had a unified -onClick event handler for all of them, which just tells the current track object to check the step number to which the box corresponds. I was faced withthe the problem of how to identify which box is which and storing its number as the user data 1 .. 16 solved this elegantly. I just ask the box whether it is checked and query the user data, which gives me enough info. -- With kind regards Veli-Pekka Tätilä (vt...@ma...) Accessibility, game music, synthesizers and programming: http://www.student.oulu.fi/~vtatila |
From: <a98...@gm...> - 2007-07-27 07:42:10
|
Hi, is it possible to show an icon within a menu? thx juergen -- Ist Ihr Browser Vista-kompatibel? Jetzt die neuesten Browser-Versionen downloaden: http://www.gmx.net/de/go/browser |
From: <jez...@ho...> - 2007-07-27 07:33:44
|
>I had a similar issue trying to launch a web browser >using system "start ..." >My workaround was to use a Win32::API call to >ShellExecuteA I also use ShellExecute - but you don't need to use Win32::API as its already in Win32::GUI. Cheers, Jez. |
From: Travis K. <kci...@ya...> - 2007-07-26 23:51:38
|
--- Robert May <rob...@us...> wrote: > I tried using > system "start temp.html"; > instead, and I see the delay you're taking about. I had a similar issue trying to launch a web browser using system "start ..." My workaround was to use a Win32::API call to ShellExecuteA Using your example: #!perl -w #use strict; #use warnings; use LWP::UserAgent; use Win32::GUI(); # Creation of the LWP Useragent # with the Firefox Cookie file my $ua = LWP::UserAgent->new; # Creation of the GUI my $main = Win32::GUI::Window->new( -title => 'Link Filter', -size => [295, 161], -maximizebox => 0, -resizable => 0, ); $main->AddLabel( -pos => [4,4], -size => [100,17], -text => 'Bitte URL eingeben:', ); $main->AddTextfield( -name => 'tfURL', -pos => [4,20], -size => [281, 77], -multiline => 1, ); $main->AddButton( -name => 'btGet', -pos => [5, 100], -size => [279,33], -text => 'Get Them!', ); $main->Center(); $main->Show(); Win32::GUI::Dialog(); $main->Hide(); sub btGet_Click { return -1; } sub open_browser { my $url=shift; use Win32::API; my $shell=Win32::API->new('shell32','ShellExecuteA','NNPNNN','N'); my $return=$shell->Call(0,0,$url,0,0,1); } my $url = $main->tfURL->Text(); $ua->get($url, ':content_file' => 'temp.html'); open_browser('temp.html'); ____________________________________________________________________________________ Get the free Yahoo! toolbar and rest assured with the added security of spyware protection. http://new.toolbar.yahoo.com/toolbar/features/norton/index.php |
From: <mar...@ar...> - 2007-07-26 23:06:37
|
Hehe, thanks for the time you spent to look over things like that. I know that you have better things to do than teaching me how to code in perl. And I think that this mailing list isn't the right place to do so. As you might have guessed I'm not the most experienced programmer on earth. At the beginning I wrote this program for my own needs. To be honest, I wrote it for exactly one specific website. But a few people asked me if they could get a copy when I'm done. That was the reason for me to create a user-friendly GUI. Now it's time for me to read some books I think. ;) Just for the sake of completeness: I'm using Windows XP Professional SP2 with all the latest windows updates. 'perl -v' output: This is perl, v5.8.8 built for MSWin32-x86-multi-thread (with 50 registered patches, see perl -V for more detail) Copyright 1987-2006, Larry Wall Binary build 820 [274739] provided by ActiveState http://www.ActiveState.com Built Jan 23 2007 15:57:46 Robert May wrote: > > I have no idea what might be causing that. I can't immediately see > how Win32::GUI could be at fault, but I am never surprised. > > I , personally, wouldn't use back-ticks to launch my browser with a > page. It's the wrong construct (it's designed to capture the stdout > of a program into a perl variable), and relies on your windows box > having particular registry entries - it certainly doesn't work for em > here. > > I tried using > system "start temp.html"; > instead, and I see the delay you're taking about. I can get rid of > the delay by doing > undef $main; > before making the system call (my code below). I'm afraid that I > don't have time to look into this further right now. (but can you post > back with the output of 'perl -v' and which windows OS you're using, > and I'll try to look at it another time. > > As an aside, if you want to extract links from HTML pages, you'd do > well to look HTML::LinkExtor, which is a full HTML parser designed to > do just this - you'll find that using regexes is not going to give you > the results you ant in the long term (for example you code won't work > if a link is split across more than one line). The docs for > HTML::LinkExtor have a nice example that shows how you can cope with > large files without having to use the intermediate temporary file that > you are using. > > Regards, > Rob. > > #!perl -w > #use strict; > #use warnings; > > use LWP::UserAgent; > use Win32::GUI(); > > # Creation of the LWP Useragent with the Firefox Cookie file > my $ua = LWP::UserAgent->new; > > # Creation of the GUI > my $main = Win32::GUI::Window->new( > -title => 'Link Filter', > -size => [295, 161], > -maximizebox => 0, > -resizable => 0, > ); > > $main->AddLabel( > -pos => [4,4], > -size => [100,17], > -text => 'Bitte URL eingeben:', > ); > > $main->AddTextfield( > -name => 'tfURL', > -pos => [4,20], > -size => [281, 77], > -multiline => 1, > ); > > $main->AddButton( > -name => 'btGet', > -pos => [5, 100], > -size => [279,33], > -text => 'Get Them!', > ); > > $main->Center(); > $main->Show(); > Win32::GUI::Dialog(); > $main->Hide(); > > sub btGet_Click { > return -1; > } > > my $url = $main->tfURL->Text(); > undef $main; # comment out this line to see the delay > > # Get the content of the Website and save it into a temporary HTML file > $ua->get($url, ':content_file' => 'temp.html'); > > system "start temp.html"; |
From: Robert M. <rob...@us...> - 2007-07-26 22:15:09
|
On 26/07/07, Marc N=FCrnberger <mar...@ar...> wrote: > Hmmmm... I found a strange behavior after adding some "debugging" prints. > The delay occurs when the last command is executed. That `links.html` > one. Everything works fine up to that point. But that's only the case > when I use the GUI version. When using the console version that command > runs without delay. Does somebody know why that occurs? I have no idea what might be causing that. I can't immediately see how Win32::GUI could be at fault, but I am never surprised. I , personally, wouldn't use back-ticks to launch my browser with a page. It's the wrong construct (it's designed to capture the stdout of a program into a perl variable), and relies on your windows box having particular registry entries - it certainly doesn't work for em here. I tried using system "start temp.html"; instead, and I see the delay you're taking about. I can get rid of the delay by doing undef $main; before making the system call (my code below). I'm afraid that I don't have time to look into this further right now. (but can you post back with the output of 'perl -v' and which windows OS you're using, and I'll try to look at it another time. As an aside, if you want to extract links from HTML pages, you'd do well to look HTML::LinkExtor, which is a full HTML parser designed to do just this - you'll find that using regexes is not going to give you the results you ant in the long term (for example you code won't work if a link is split across more than one line). The docs for HTML::LinkExtor have a nice example that shows how you can cope with large files without having to use the intermediate temporary file that you are using. Regards, Rob. #!perl -w #use strict; #use warnings; use LWP::UserAgent; use Win32::GUI(); # Creation of the LWP Useragent with the Firefox Cookie file my $ua =3D LWP::UserAgent->new; # Creation of the GUI my $main =3D Win32::GUI::Window->new( -title =3D> 'Link Filter', -size =3D> [295, 161], -maximizebox =3D> 0, -resizable =3D> 0, ); $main->AddLabel( -pos =3D> [4,4], -size =3D> [100,17], -text =3D> 'Bitte URL eingeben:', ); $main->AddTextfield( -name =3D> 'tfURL', -pos =3D> [4,20], -size =3D> [281, 77], -multiline =3D> 1, ); $main->AddButton( -name =3D> 'btGet', -pos =3D> [5, 100], -size =3D> [279,33], -text =3D> 'Get Them!', ); $main->Center(); $main->Show(); Win32::GUI::Dialog(); $main->Hide(); sub btGet_Click { return -1; } my $url =3D $main->tfURL->Text(); undef $main; # comment out this line to see the delay # Get the content of the Website and save it into a temporary HTML file $ua->get($url, ':content_file' =3D> 'temp.html'); system "start temp.html"; |
From: <mar...@ar...> - 2007-07-26 21:27:11
|
Hmmmm... I found a strange behavior after adding some "debugging" prints. The delay occurs when the last command is executed. That `links.html` one. Everything works fine up to that point. But that's only the case when I use the GUI version. When using the console version that command runs without delay. Does somebody know why that occurs? Regards, Marc |
From: <mar...@ar...> - 2007-07-26 20:45:10
|
Robert May wrote: > #!perl -w > use strict; > use warnings; > use Win32 qw(CSIDL_APPDATA); > > print Win32::GetShortPathName(Win32::GetFolderPath(CSIDL_APPDATA)), "\n"; > __END__ > > That will get what you need, and work for all versions of Win32 from > Win95 through Vista - $ENV{APPDATA} will only work from Win2K(?) > onwards. Thanks for that one! > Looking at your original code, I'm not sure what you think the problem > is. Presumably the delay is while the file is fetched from the remote > site - you leave the GUI up, but it will be non-responsive. If you > just want to dismiss the GUI, then add > $main->Hide() > after your Win32::GUI::Dialog(); line. > > Regards, > Rob. The problem is, that it would never take about 30 seconds to fetch that file. If I use a console based version of this program, it's finished in about 2-3 seconds. :) Regards, Marc |
From: Robert M. <rob...@us...> - 2007-07-26 20:26:59
|
On 25/07/07, Veli-Pekka T=E4til=E4 <vt...@ma...> wrote: > Secondly, I know this is much easier said than done, but would be great > if the GridLayout control could be improved to be more like layout > managers are in other UIs. I'd like to see a family of layout modules, offering capabilities from the simplest grid layout through more complex schemes. I'm got a half-written layout manager that works somewhat like Tk's pack() command, but I'm not doing well on finding the tuits to complete it. > Java's Swing has excellent layout managers that fill both gaps I > mentioned but they are fairly complex. I've found that Gnome's take on > things is relatively simple to use and gets most jobs done all right. > Here's a brief and high-level explanation with in-line imagery: > > <http://www.gtk.org/tutorial1.2/gtk_tut-4.html> Thanks - I hadn't seen this one before. Having read it, I think that what I'm working on, along with an enhanced grid layout manager would probably do just about everything I can think of. > As GTK+ is open source, I wonder if you could actually borrow some of > the code doing the hard parts and rewrite only Win32 specific bits. The > grid control could then be XS code, too, like most of the Win32::GUI > package appears to be -> at least I cannot find many pm files. I'm not sure that it's a very hard problem - box layout is a well understood problem, it's just a bit tedious getting all the calculations correct and not having any 'off by one' errors. I'm actually of the opinion that we should be moving more of the code back into perl from XS. I don't think that speed is really much of an issue for most GUI apps - and if we do have performance problems we could keep the critical bits in XS. The biggest advantage of moving more of the code into perl would be that people who are not Win32 API gurus can see how things are done, and modify things that they need to. I've got a side project going on at the moment to look at this. > This is minority stuff, but optionally having the grid start its > indexing at $[ would be cool, too. While we're at this, could not you > make a grid object that works like an array or ref to one but let's you > call methods on it? Usage would be more intuitive then. I thought about > this and tentatively concluded that Perl 5 cannot do that. Tied arrays > lose their objectness and having the user directly access object > internals as an array leads one to trouble, even if you'd store object > data at the end or have per-object data as elements in a class array > datum. OBjects that also look like arrays are trivial in, say, Ruby, > though I mostly use Perl because of PPM and all the nifty modules like > Win32::GUI, for example. For me this is an accessibility issue, my > screen reader does not support most 3rd party UIs. overloading allows objects to look like arrays - its not something I've played with extensively, and I'm not sure that you can asign to the array, but try reading up on the overload.pm pragma. Regards, Rob. |
From: Robert M. <rob...@us...> - 2007-07-26 20:03:17
|
On 25/07/07, Salvador Ortiz Garc=EDa <so...@ms...> wrote: > On Wed, 2007-07-25 at 16:29 +0300, Veli-Pekka T=E4til=E4 wrote: > > Hi list, > > I think I've found a bug or oddity in Win32::GUI::AcceleratorTable > > ... > > Yes, right now only the internal handlers are stored in the associated > window, a bug IMHO. Probably, but it's not a straightforward fix. > BTW the same happens with a menu. and fonts, and probably other non-window objects. > As time permits I've be working in a proper fix, That's great - I look forward to it. You might want to have a discussion with me about this, as I've looked into it briefly before, and if I remember correctly there are a number of edge cases to watch out for. > but as a quick > workaround in my apps I store the perl objects in the window hash: It's better practice to use the UserData() or ClassData() methods to store data with a window - that's the documented interface - and will remain supported. Poking directly into the representation of an Object is unhealthy. Regards, Rob. |
From: Robert M. <rob...@cp...> - 2007-07-26 19:55:19
|
On 26/07/07, Marc N=FCrnberger <mar...@ar...> wrote: > Hi there, > > first of all thanks for your quick answers. > > Geoffrey Spear wrote: > > I don't have a solution for your freezing problem, but you should be > > able to replace "C:/Docume~1/$ENV{'USERNAME'}/Anwendungsdaten" with > > "$ENV{'APPDATA'}" and have it work in any locale. > > I could do that, but because of the used glob() function I can't. > Because C:\Documents and Settings\ contains whitespaces which glob() > can't handle (as far as I read everywhere). It would end up with > C:\Documents all the time. > But I need the glob() here to get into the <random_number>.default > Firefox profile folder. > I did something "easier"... I rebuilt the GUI with another button which > opens a file browser. Now I can select the cookie file on my own. ;) #!perl -w use strict; use warnings; use Win32 qw(CSIDL_APPDATA); print Win32::GetShortPathName(Win32::GetFolderPath(CSIDL_APPDATA)), "\n"; __END__ That will get what you need, and work for all versions of Win32 from Win95 through Vista - $ENV{APPDATA} will only work from Win2K(?) onwards. > Jason Plum wrote: > > This is not a GUI issue per se, as it is the fact that your routine > > runs > > synchronous, in the main thread of the application. To remove this lag > > (and > > the delayed drawing of the window) you will need to do some looking > > through > > the mail archives and find how to write this into a separate thread. > > Hmm... i will try to read me into this > Thanks for your help. :) Looking at your original code, I'm not sure what you think the problem is. Presumably the delay is while the file is fetched from the remote site - you leave the GUI up, but it will be non-responsive. If you just want to dismiss the GUI, then add $main->Hide() after your Win32::GUI::Dialog(); line. Regards, Rob. |
From: <mar...@ar...> - 2007-07-26 19:06:27
|
Hi there, first of all thanks for your quick answers. Geoffrey Spear wrote: > I don't have a solution for your freezing problem, but you should be > able to replace "C:/Docume~1/$ENV{'USERNAME'}/Anwendungsdaten" with > "$ENV{'APPDATA'}" and have it work in any locale. I could do that, but because of the used glob() function I can't. Because C:\Documents and Settings\ contains whitespaces which glob() can't handle (as far as I read everywhere). It would end up with C:\Documents all the time. But I need the glob() here to get into the <random_number>.default Firefox profile folder. I did something "easier"... I rebuilt the GUI with another button which opens a file browser. Now I can select the cookie file on my own. ;) Jason Plum wrote: > This is not a GUI issue per se, as it is the fact that your routine > runs > synchronous, in the main thread of the application. To remove this lag > (and > the delayed drawing of the window) you will need to do some looking > through > the mail archives and find how to write this into a separate thread. Hmm... i will try to read me into this Thanks for your help. :) |
From: Jason P. <jp...@un...> - 2007-07-26 13:45:05
|
This is not a GUI issue per se, as it is the fact that your routine runs synchronous, in the main thread of the application. To remove this lag = (and the delayed drawing of the window) you will need to do some looking = through the mail archives and find how to write this into a separate thread. -----Original Message----- From: per...@li... [mailto:per...@li...] On Behalf Of Marc N=FCrnberger Sent: Thursday, July 26, 2007 7:21 AM To: per...@li... Subject: [perl-win32-gui-users] Why is my GUI hanging? Hi everyone, I tried to create a little GUI for a program which I wrote a while ago. It's only a little link filter. I have to give him an URL, he parses the website for given regular expressions and gives back a HTML file with all the links in it. Now the problem is that if i enter the URL and click on the Button to proceed, the program hangs for about 30 seconds before it goes on. Everything works fine. Only this "lag" is very disappointing. I can't find my mistake... If I do the same on the console, everything works instantly without = hanging. I would be glad if someone could help me out. :) Here's the code: use LWP::UserAgent; use HTTP::Cookies::Mozilla; use Win32::GUI(); # Use of the Firefox Cookie file # For German Systems: Change the Docume~1 to Dokume~1 # I'm working on a better solution for this $kekse =3D HTTP::Cookies::Mozilla->new( 'file' =3D> glob("C:/Docume~1/$ENV{'USERNAME'}/Anwendungsdaten/Mozilla/Firefox/Profil= es/ *.default/cookies.txt")); # Creation of the LWP Useragent with the Firefox Cookie file $ua =3D LWP::UserAgent->new; $ua->agent('Mozilla/5.0'); $ua->cookie_jar($kekse); # Creation of the GUI $main =3D Win32::GUI::Window->new( -name =3D> 'Main', -width =3D> $width =3D 295, -height =3D> $height =3D 161, -maximizebox =3D> 0, -resizable =3D> 0, -text =3D> 'Link Filter', ); $lblURL =3D $main->AddLabel( -name =3D> 'lblURL', -width =3D> 100, -height =3D> 17, -align =3D> 'left', -left =3D> 4, -top =3D> 4, -text =3D> 'Bitte URL eingeben:', ); $tfURL =3D $main->AddTextfield( -name =3D> 'tfURL', -width =3D> 281, -height =3D> 77, -align =3D> 'left', -left =3D> 4, -top =3D> 20, -multiline =3D> 1, ); $btGet =3D $main->AddButton( -name =3D> 'btGet', -width =3D> 279, -height =3D> 33, -left =3D> 5, -top =3D> 100, -text =3D> 'Get Them!', ); $desk =3D Win32::GUI::GetDesktopWindow(); $deskwidth =3D Win32::GUI::Width($desk); $deskheight =3D Win32::GUI::Height($desk); $deskx =3D ($deskwidth - $width) / 2; $desky =3D ($deskheight - $height) / 2; $main->Move($deskx, $desky); $main->Show(); Win32::GUI::Dialog(); sub Main_Terminate { return -1; } sub btGet_Click { # Copy the entered URL into a usable variable $url =3D $tfURL->Text; return -1; } # Get the content of the Website and save it into a temporary HTML file $ua->get($url, ':content_file' =3D> 'temp.html'); open(EINGABE, "temp.html") || die("Fehler: Datei temp.html konnte nicht gefunden werden."); open(AUSGABE, ">links.html") || die("Fehler: konnte Datei rs.html nicht erstellen."); # Filter the links from the temporary file and write them into a new HTML file while($zeile =3D <EINGABE>) { if ($zeile =3D~ m/ENTER YOUR REGEXP HERE/) { $zeile =3D~ s/ENTER YOUR REGEXP HERE/AND HERE/; print AUSGABE "<a href=3D\"" . $zeile . "\">" . $zeile . "</a>" . "<br>"; } } close(EINGABE); close(AUSGABE); # Delete temporary file unlink "temp.html"; # Open the file which holds the filtered links `links.html`; -------------------------------------------------------------------------= This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ Perl-Win32-GUI-Users mailing list Per...@li... https://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users http://perl-win32-gui.sourceforge.net/ --=20 No virus found in this incoming message. Checked by AVG Free Edition.=20 Version: 7.5.476 / Virus Database: 269.10.20/919 - Release Date: = 7/26/2007 9:56 AM |
From: <mar...@ar...> - 2007-07-26 11:21:32
|
Hi everyone, I tried to create a little GUI for a program which I wrote a while ago. It's only a little link filter. I have to give him an URL, he parses the website for given regular expressions and gives back a HTML file with all the links in it. Now the problem is that if i enter the URL and click on the Button to proceed, the program hangs for about 30 seconds before it goes on. Everything works fine. Only this "lag" is very disappointing. I can't find my mistake... If I do the same on the console, everything works instantly without hanging. I would be glad if someone could help me out. :) Here's the code: use LWP::UserAgent; use HTTP::Cookies::Mozilla; use Win32::GUI(); # Use of the Firefox Cookie file # For German Systems: Change the Docume~1 to Dokume~1 # I'm working on a better solution for this $kekse = HTTP::Cookies::Mozilla->new( 'file' => glob("C:/Docume~1/$ENV{'USERNAME'}/Anwendungsdaten/Mozilla/Firefox/Profiles/*.default/cookies.txt")); # Creation of the LWP Useragent with the Firefox Cookie file $ua = LWP::UserAgent->new; $ua->agent('Mozilla/5.0'); $ua->cookie_jar($kekse); # Creation of the GUI $main = Win32::GUI::Window->new( -name => 'Main', -width => $width = 295, -height => $height = 161, -maximizebox => 0, -resizable => 0, -text => 'Link Filter', ); $lblURL = $main->AddLabel( -name => 'lblURL', -width => 100, -height => 17, -align => 'left', -left => 4, -top => 4, -text => 'Bitte URL eingeben:', ); $tfURL = $main->AddTextfield( -name => 'tfURL', -width => 281, -height => 77, -align => 'left', -left => 4, -top => 20, -multiline => 1, ); $btGet = $main->AddButton( -name => 'btGet', -width => 279, -height => 33, -left => 5, -top => 100, -text => 'Get Them!', ); $desk = Win32::GUI::GetDesktopWindow(); $deskwidth = Win32::GUI::Width($desk); $deskheight = Win32::GUI::Height($desk); $deskx = ($deskwidth - $width) / 2; $desky = ($deskheight - $height) / 2; $main->Move($deskx, $desky); $main->Show(); Win32::GUI::Dialog(); sub Main_Terminate { return -1; } sub btGet_Click { # Copy the entered URL into a usable variable $url = $tfURL->Text; return -1; } # Get the content of the Website and save it into a temporary HTML file $ua->get($url, ':content_file' => 'temp.html'); open(EINGABE, "temp.html") || die("Fehler: Datei temp.html konnte nicht gefunden werden."); open(AUSGABE, ">links.html") || die("Fehler: konnte Datei rs.html nicht erstellen."); # Filter the links from the temporary file and write them into a new HTML file while($zeile = <EINGABE>) { if ($zeile =~ m/ENTER YOUR REGEXP HERE/) { $zeile =~ s/ENTER YOUR REGEXP HERE/AND HERE/; print AUSGABE "<a href=\"" . $zeile . "\">" . $zeile . "</a>" . "<br>"; } } close(EINGABE); close(AUSGABE); # Delete temporary file unlink "temp.html"; # Open the file which holds the filtered links `links.html`; |
From: Salvador O. <so...@ms...> - 2007-07-25 20:56:53
|
On Wed, 2007-07-25 at 16:29 +0300, Veli-Pekka Tätilä wrote: > Hi list, > I think I've found a bug or oddity in Win32::GUI::AcceleratorTable > ... Yes, right now only the internal handlers are stored in the associated window, a bug IMHO. BTW the same happens with a menu. As time permits I've be working in a proper fix, but as a quick workaround in my apps I store the perl objects in the window hash: sub CreateAll { my $menu = Win32::GUI::MakeMenu(...); my $accel = Win32::GUI::AcceleratorTable->new(...); my $rootWin = Win32::GUI::Window->new( ... -menu => $menu, -accel => $accel, ... ); # Workaround for window not storing the perl object. # I use the '_' prefix to avoid name clashes with child's named $rootWin->{_Menu} = $menu; $rootWin->{_Accel} = $accel; ... return $rootWin; } -- Salvador Ortiz García <so...@ms...> Matías Software Group |
From: Travis K. <kci...@ya...> - 2007-07-25 17:45:22
|
<jac...@er...> wrote: > Hi to everyone! > > The issue here is as follows: > I have a listbox and a user selects one item. Then > the Perl script > processes the selection. > After processing, I need to unselect the selected > item, not delete it. I > have not yet found a method to do this. > > Can you help? > > Thank you. For single selection listboxes: SetCurSel(-1) To clear the selection of one item in a multiple selection listbox: SetSel(index,0) To clear all the selections in a multiple selection listbox: SetSel(-1,0) ____________________________________________________________________________________ Take the Internet to Go: Yahoo!Go puts the Internet in your pocket: mail, news, photos & more. http://mobile.yahoo.com/go?refer=1GNXIC |
From: Jacques C. XX \(QB/EMC\) <jac...@er...> - 2007-07-25 14:20:59
|
Hi to everyone! The issue here is as follows: I have a listbox and a user selects one item. Then the Perl script processes the selection. After processing, I need to unselect the selected item, not delete it. I have not yet found a method to do this. Can you help? Thank you. ------------------------------------------------ From: Jacques Choquette Sun Hardware Admin Tel: 514-345-7900 x 43463 |
From: Veli-Pekka <vt...@ma...> - 2007-07-25 13:29:43
|
Hi list, I think I've found a bug or oddity in Win32::GUI::AcceleratorTable and have vague suggestions on how to improve the already very handy GridLayout control. I've discovered that if the accelerator object associated with a window goes out of scope, the accelerators appear to stop working for that window. This is quite odd in that I thought Perl's reference counting would ensure that the object won't get destroyed until all references to it have been. Surely a window with an accelerator has a reference to that accelerator, right? Maybe it only stores the handle of the actual Win32 accelerator table and not a Perl reference, this would explain a lot. Here's a barebones script to demonstrate the problem. FIrst the case where the accelerators are global: use strict; use warnings; use Win32::GUI; my $keys = Win32::GUI::AcceleratorTable->new(a => sub{ print "A" }); my $win = Win32::GUI::Window->new ( -size => [320, 200], -accel => $keys, -onTerminate => sub { -1 }, -onTimer => sub { print "." }, ); $win->AddTimer(clock => 1000); $win->Show(); Win32::GUI::Dialog(); This works as expected printing the dots when the timer gets triggered and printing a when-ever you hit the letter a and the window has the focus. Now, say we write a sub that returns the main window and associates it with an accelerator. The differences to the above are the third statement: my $win = mainWindow(); and later the almost identical code in the sub: sub mainWindow { my $keys = Win32::GUI::AcceleratorTable->new ( a => sub{ print "A" } ); return Win32::GUI::Window->new ( -size => [320, 200], -accel => $keys, -onTerminate => sub { -1 }, -onTimer => sub { print "." }, ); } # sub These changes result in the accelerators not working i.e. the functions don't get called. Secondly, I know this is much easier said than done, but would be great if the GridLayout control could be improved to be more like layout managers are in other UIs. I see two primary problems with it. As it is not really a Win32::GUI control in the traditional sense, you cannot nest grids inside each other for complex layouts. secondly, the grid is equally spaced as far as I've understood it. Would be nice if it adapted to the size of the control put in a particular location, so you could layout a grid without having to worry about the containing controls' sizes, Java's Swing has excellent layout managers that fill both gaps I mentioned but they are fairly complex. I've found that Gnome's take on things is relatively simple to use and gets most jobs done all right. Here's a brief and high-level explanation with in-line imagery: <http://www.gtk.org/tutorial1.2/gtk_tut-4.html> As GTK+ is open source, I wonder if you could actually borrow some of the code doing the hard parts and rewrite only Win32 specific bits. The grid control could then be XS code, too, like most of the Win32::GUI package appears to be -> at least I cannot find many pm files. This is minority stuff, but optionally having the grid start its indexing at $[ would be cool, too. While we're at this, could not you make a grid object that works like an array or ref to one but let's you call methods on it? Usage would be more intuitive then. I thought about this and tentatively concluded that Perl 5 cannot do that. Tied arrays lose their objectness and having the user directly access object internals as an array leads one to trouble, even if you'd store object data at the end or have per-object data as elements in a class array datum. OBjects that also look like arrays are trivial in, say, Ruby, though I mostly use Perl because of PPM and all the nifty modules like Win32::GUI, for example. For me this is an accessibility issue, my screen reader does not support most 3rd party UIs. Finally, my machine says: This is perl, v5.8.8 built for MSWin32-x86-multi-thread (with 50 registered patches, and also, Documentation for Win32::GUI v1.03 created 16 Mar 2006 Hope this can be of help. -- With kind regards Veli-Pekka Tätilä (vt...@ma...) Accessibility, game music, synthesizers and programming: http://www.student.oulu.fi/~vtatila |
From: Reini U. <ru...@x-...> - 2007-07-23 16:57:53
|
Not really new, this was in my public repo since 2006-11-08, just forgot to upload it. NEWS: ===== I've updated the cygwin version of perl-Win32-GUI to the upstream release 1.05. This version is the same as it would have been installed via CPAN, since all cygwin patches are included upstream. It just installs into vendor_perl. CHANGES: ======== This release is a bug-fix release addressing the issues at http://sourceforge.net/forum/forum.php?forum_id=630109. DESCRIPTION: ============ Win32::GUI is a Perl extension allowing creation of native Win32 GUI applications. UPDATE: ======= To update your installation, click on the "Install Cygwin now" link on the http://cygwin.com/ web page. This downloads setup.exe to your system. Save it and run setup, answer the questions and pick up the package name from the 'Libs' category (it should already be selected). DOWNLOAD: ========= Note that downloads from sources.redhat.com (aka cygwin.com) aren't allowed due to bandwidth limitations. This means that you will need to find a mirror which has this update, please choose the one nearest to you: http://cygwin.com/mirrors.html QUESTIONS: ========== If you want to make a point or ask a question the Cygwin mailing list is the appropriate place. CYGWIN-ANNOUNCE UNSUBSCRIBE INFO: ================================= To unsubscribe to the cygwin-announce mailing list, look at the "List-Unsubscribe: " tag in the email header of this message. Send email to the address specified there. It will be in the format: cygwin-announce-unsubscribe-YOU=YOU...@cy... If you need more information on unsubscribing, start reading here: http://sources.redhat.com/lists.html#unsubscribe-simple Please read *all* of the information on unsubscribing that is available starting at this URL. |
From: Robert M. <rob...@us...> - 2007-07-12 19:02:46
|
On 12/07/07, pcourterelle <pco...@te...> wrote: > Yes I understood the meaning of the description fine and I'm not questioning > whether the code works. It just never worked in my implementation. I took > the meaning of the description to mean that when the TopIndex is set to (0) > the item at (0) will be visible in the Listbox window. Yes the scrollbar is > visible and active and the drop down works with scrollbar. It's must more obvious with an old-style listbox (code below). In the case of a drop-down list box it appears that clicking the drop-down-arrow resets the list to the top if there's no selection in the combo/edit box. If you open drop-down-list before calling SetTopIndex(), then you can also see it happening orrectly (again, code below). Hope this helps. Regards, Rob. #! perl -w use strict; use warnings; use Win32::GUI 1.05 qw(CW_USEDEFAULT); my $mw = Win32::GUI::Window->new( -left => CW_USEDEFAULT, -size => [400,300], ); my $cb = $mw->AddCombobox( -pos => [10,10], -size => [200,100], -vscroll => 1, ); $cb->Add($_) for (0 .. 99); $cb->SetTopIndex(50); $mw->Show(); Win32::GUI::Dialog(); $mw->Hide(); exit(0); __END__ #! perl -w use strict; use warnings; use Win32::GUI 1.05 qw(CW_USEDEFAULT); my $mw = Win32::GUI::Window->new( -left => CW_USEDEFAULT, -size => [400,300], ); my $cb = $mw->AddCombobox( -pos => [10,10], -size => [200,100], -vscroll => 1, -dropdownlist => 1, ); $cb->Add($_) for (0 .. 99); $cb->ShowDropDown(1); $cb->SetTopIndex(50); $mw->Show(); Win32::GUI::Dialog(); $mw->Hide(); exit(0); __END__ |
From: pcourterelle <pco...@te...> - 2007-07-12 05:14:49
|
----- Original Message ----- From: "Robert May" <rob...@us...> To: "pcourterelle" <pco...@te...> Cc: <per...@li...> Sent: Wednesday, July 11, 2007 2:29 PM Subject: Re: [perl-win32-gui-users] combobox > On 04/07/07, pcourterelle <pco...@te...> wrote: >> Rob, thanks for that...that drove me nuts for a while...what does >> SetTopIndex() do if it does ensure the value of the index is visible in >> the >> Listbox? The info says: >> >> SetTopIndex >> SetTopIndex(INDEX) >> Ensure that a particular item is visible in the Listbox of a Combobox. >> >> Just curious. > > It does what it says. You need to understand that the 'Listbox of a > combobox' is the drop-down window that you to select items in; It > makes sure that the item referred to by INDEX is within the visible > window - you'll only notice it do anything if you have enough items in > the listbox such that the drop-down needs to scroll to see some items, > AND the dropdown is visible. > > Regards > Rob. > Yes I understood the meaning of the description fine and I'm not questioning whether the code works. It just never worked in my implemenation. I took the meaning of the descrpition to mean that when the TopIndex is set to (0) the item at (0) will be visible in the Listbox window. Yes the scrollbar is visible and active and the drop down works with scrollbar. Sample below. #! perl -w use strict; use Win32::GUI; my $MainWindow = new Win32::GUI::Window( -name => "MainWindow", -size => [300,400], -pos => [100,200], ); $MainWindow->AddCombobox( -name => "FilterList", -autoscroll => 1, -dropdown => 1, -dropdownlist => 1, -size => [200,100], -height => 100, -pos => [$MainWindow->Width*0.05,$MainWindow->Height*0.055], -vscroll => 1, ); PopulateCombo(); #------------------------ $MainWindow->Show(); Win32::GUI::Dialog(); #------------------------ sub PopulateCombo{ foreach (qw(Big Bad Bob Bothers Brothers Because Bob Bake Bundt Batter By Batteries)){ $MainWindow->FilterList->Add($_); } $MainWindow->FilterList->SetTopIndex(1); } #--- end---- |
From: Robert M. <rob...@us...> - 2007-07-11 21:36:39
|
On 11/07/07, Robert May <rob...@us...> wrote: > On 11/07/07, a98...@gm... <a98...@gm...> wrote: > > I have a small program which can be minimized to the tray. > > Now I want to have an accelerator which fires to minimize the program to the > > tray => this works fine. > > But now I want to restore the window with an accelerator anytime. > > It should work if I'm writing a text or in internet explorer or firefox ... everytime. > > is this possible? > > how can I install the accelerator so that it can be activated? > > I'll attach some code that shows the WM_SETHOTKEY method to this mail > - it doesn't quite meet your requirements, but it's close and can be > done with Win32::GUI alone. I'll follow-up with code that uses the > Win32 RegisterHotKey() function - I think it exactly meets what you > want to do, but needs Win32::API() to call the functions that are > missing from Win32::GUI. This is the follow-up using RegisterHotKey() and WM_HOTKEY. It's a bit more complex than the last example: #!perl -w use strict; use warnings; # What this script does: # Creates a Window, and a notify icon. # Register a Hotkey (Ctrl-A) for the window. # When the window is minimised, it is hidden. # Left-clicking on the notify icon, or pressing the # Hotkey combination will Show the window again. # Pressing the HotKey when the window is visible # hides it. # We can't use WM_SETHOTKEY, as we never see any WM_SYSCOMMAND # once the window is hidden, so we use Win32::API to give # us access to RegisterHotKey/UnregisterHotKey and catch # the WM_HOTKEY messages to o our bidding. use Win32::API(); Win32::API->Import('user32', 'RegisterHotKey', 'LiII', 'I'); Win32::API->Import('user32', 'UnregisterHotKey', 'Li', 'I'); use Win32::GUI 1.05 qw( CW_USEDEFAULT WM_HOTKEY VK_A IDI_DEFAULTICON ); # Some constants missing from Win32::GUI::Constants sub MOD_ALT() {0x001} # Alt key sub MOD_CONTROL() {0x002} # Ctrl key sub MOD_SHIFT() {0x004} # Shift key sub MOD_WIN() {0x008} # Windows key my $HOTKEY_ID = 0x1234; # Any unique number for this app - need # a different number for each hotkey my $mw = Win32::GUI::Window->new( -title => 'HotKey demonstration', -left => CW_USEDEFAULT, -size => [400,300], -onMinimize => \&toggle_show_state, ); # We need to catch WM_HOTKEY messages $mw->Hook(WM_HOTKEY, \&handle_wm_hotkey); my $icon = Win32::GUI::Icon->new(IDI_DEFAULTICON); $mw->AddNotifyIcon( -icon => $icon, -onClick => \&toggle_show_state, ); set_hotkey($mw, $HOTKEY_ID, VK_A, MOD_CONTROL); $mw->Show(); Win32::GUI::Dialog(); # Before we exit we must remove the hotkey, else it won't be available # for other apps, and we'll leak system memory # Using and END block to that this get called, even if we exit other # than by falling off the end here. END { unset_hotkey($mw, $HOTKEY_ID); } sub toggle_show_state { my ($win) = @_; # Less obviously written as: # $win->Show(!$win->IsVisible()); if($win->IsVisible()) { $win->Hide(); } else { $win->Show(); } return 0; } # Set the hotkey for a window (or replace it if this is called # more than once) sub set_hotkey { my ($win, $id, $key, $modifiers) = @_; # $win - any top level window # $id - unique identifier for the hotkey # $key - any virtual keycode (VK_*) except F12 (and others??) # $modifiers - any combination of the MOD_* constants (or 0 for no modifier) if(!RegisterHotKey($win->{-handle}, $id, $modifiers, $key)) { die("set_hotkey() failed to register the hotkey - $^E"); } return; } sub unset_hotkey { my ($win, $id) = @_; # $win - any top level window # $id - unique identifier for the hotkey if(!UnregisterHotKey($win->{-handle}, $id)) { die("unset_hotkey() failed to unregister the hotkey - $^E"); } return; } sub handle_wm_hotkey { my ($win, $id, $lparam, $type, $msgcode) = @_; return unless $type == 0; return unless $msgcode == WM_HOTKEY; # decode virtual key and modifiers from lparam: # my ($modifiers, $key) = unpack("SS", pack("L", $lparam)); # my $mod = ''; # $mod .= "A" if($modifiers & MOD_ALT); # $mod .= "C" if($modifiers & MOD_CONTROL); # $mod .= "S" if($modifiers & MOD_SHIFT); # $mod .= "W" if($modifiers & MOD_WIN); # print "Saw WM_HOTKEY with id: $id (vkey: $key, mod: $mod)\n"; # should really check ID to determine what to do, but we can get # away without that, as we only have one hotkey toggle_show_state($win); return; } |
From: Robert M. <rob...@us...> - 2007-07-11 21:34:57
|
On 11/07/07, a98...@gm... <a98...@gm...> wrote: > I have a small program which can be minimized to the tray. > Now I want to have an accelerator which fires to minimize the program to the > tray => this works fine. > But now I want to restore the window with an accelerator anytime. > It should work if I'm writing a text or in internet explorer or firefox ... everytime. > is this possible? > how can I install the accelerator so that it can be activated? Yes, it's possible, you'll find it discussed on this list if you search for WM_HOTKEY or WM_SETHOTKEY (these are 2 slightly different techniques. I'll attach some code that shows the WM_SETHOTKEY method to this mail - it doesn't quite meet your requirements, but it's close and can be done with Win32::GUI alone. I'll follow-up with code that uses the Win32 RegisterHotKey() function - I think it exactly meets what you want to do, but needs Win32::API() to call the functions that are missing from Win32::GUI. Regards, Rob. #!perl -w use strict; use warnings; # What this script does: # Creates a Window, and a notify icon. # Register a Hotkey (Ctrl-A) for the window. # When the window is minimised, it is not hidden. # Left-clicking on the notify icon, or pressing the # Hotkey combination will Show the window again. # In this example, we can't hide the window, as if we do, then # I can't find a suitable hook into the message system to know # when to show the window again. use Win32::GUI 1.05 qw( CW_USEDEFAULT WM_SETHOTKEY VK_A IDI_DEFAULTICON ); # Some constants missing from Win32::GUI::Constants sub HOTKEYF_SHIFT() {0x01} # Shift key sub HOTKEYF_CONTROL() {0x02} # Ctrl key sub HOTKEYF_ALT() {0x04} # Alt key sub HOTKEYF_EXT() {0x08} # Extended key (??) my $mw = Win32::GUI::Window->new( -title => 'HotKey demonstration', -left => CW_USEDEFAULT, -size => [400,300], ); my $icon = Win32::GUI::Icon->new(IDI_DEFAULTICON); $mw->AddNotifyIcon( -icon => $icon, -onClick => \&show_window, ); set_hotkey($mw, VK_A, HOTKEYF_CONTROL); $mw->Show(); Win32::GUI::Dialog(); sub show_window { my ($win) = @_; $win->Show(); return 0; } # Set the hotkey for a window (or replace it if this is called # more than once) sub set_hotkey { my ($win, $key, $modifier) = @_; # $win - any top level window # $key - any virtual keycode (VK_*) Esc, TAB, SPACE and a few others. # $modifier: any combination of the HOTKEYF_* constants (or 0 for no modifier) # Watch out. Despite what the MS documentation says the modifier # goes in the upper byte of a short, not the upper WORD of a # DWORD. I.e. the left shift is 8 bits, not 16 bits my $wParam = ($modifier << 8) + $key; # Set the hotkey for the window by sending a WM_SETHOTKEY # message. If successful pressing the hokey combination # results in a WM_SYSCOMMAND message being sent to the registered window # with wParam equl to SC_HOTKEY. DefWindowProc process this by bringing # the window to the foreground. my $ret = $win->SendMessage(WM_SETHOTKEY, $wParam, 0); if($ret == -1) { die('set_hotkey() failed to register the hotkey - invalid hotkey'); } elsif($ret == 0) { die('set_hotkey() failed to register the hotkey - invalid window'); } elsif($ret == 1) { # success } elsif($ret == 2) { warn('set_hotkey(): registered hotkey, but another window has the '. "same hotkey.\nThe window activated by the hotkey will be". "randomly selected\n"); } else { die('set_hotkey(): unexpected return value from WM_SETHOTKEY'); } return; } |
From: Robert M. <rob...@us...> - 2007-07-11 21:29:05
|
On 04/07/07, pcourterelle <pco...@te...> wrote: > Rob, thanks for that...that drove me nuts for a while...what does > SetTopIndex() do if it does ensure the value of the index is visible in the > Listbox? The info says: > > SetTopIndex > SetTopIndex(INDEX) > Ensure that a particular item is visible in the Listbox of a Combobox. > > Just curious. It does what it says. You need to understand that the 'Listbox of a combobox' is the drop-down window that you to select items in; It makes sure that the item referred to by INDEX is within the visible window - you'll only notice it do anything if you have enough items in the listbox such that the drop-down needs to scroll to see some items, AND the dropdown is visible. Regards Rob. |