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: Erick J. B. <er...@e-...> - 2001-02-14 14:08:30
|
When inserting an item, there does not seem to be an option for setting the item as checked or not. I think I would have to use the SetItem method, but there is no documentaion on this. Does anyone know? erick never stop questioning www.jeb.ca |
From: Aldo C. <da...@pe...> - 2001-02-14 13:51:45
|
Nahum Marc wrote: > I do this too ... but it's close the window , and not all the > script ... I can see the process yet in task manager (under NT4) > > off course , i hide the dos box so , i need kill the process there must be some error in your script. can you post a piece of your code that includes at least the window creation, the Win32::GUI::Dialog() call and the Terminate event? also, please report which version of Win32::GUI and Perl and operating system you're using. cheers, Aldo __END__ $_=q,just perl,,s, , another ,,s,$, hacker,,print; |
From: Aldo C. <da...@pe...> - 2001-02-14 13:24:23
|
christopher sagayam wrote: > Here is what Im trying to do > > I am trying to write a win32 gui perl client which when started > will check whether the computer is connected to internet > continuously indefinety in the meantime other actions should > proceed also > > So based on your previous example actually there wont be a STOP > button at all since this loop is going to be continuouly executed > as along as the win32 gui script is running > > now the catch is during the time the loop is running I need to > catch key presses , button presses , tab presses etc too and do > it efficiently I see. in this case, the best thing to do is to setup a Timer object with a small interval and do your connectivity test once inside its Timer event, no loop, no sleep :-) cheers, Aldo __END__ $_=q,just perl,,s, , another ,,s,$, hacker,,print; |
From: christopher s. <chr...@ya...> - 2001-02-14 12:53:15
|
Thanks aldo I will use DO event but in case there is a better solution do keep me posted Here is what Im trying to do I am trying to write a win32 gui perl client which when started will check whether the computer is connected to internet continuously indefinety in the meantime other actions should proceed also So based on your previous example actually there wont be a STOP button at all since this loop is going to be continuouly executed as along as the win32 gui script is running now the catch is during the time the loop is running I need to catch key presses , button presses , tab presses etc too and do it efficiently Thanks chris ----- Original Message ----- From: Aldo Calpini <da...@pe...> To: christopher sagayam <per...@li...> Sent: Wednesday, February 14, 2001 3:47 PM Subject: Re: [perl-win32-gui-users] looping in win32 GUI christopher sagayam wrote: > $|=1; > use Win32::RASE; > eval "use Time::HiRes qw(sleep)"; > $hrasconn = (RasEnumConnections())[1]; > $old_status = -1; > while ( ($status, $status_text) = RasGetConnectStatus($hrasconn) ) { > if ($status != $old_status) { > print "$status: $status_text\n"; > $old_status = $status; > } > sleep ($@ ? 1 : 0.01); > } > # error 6 - Invalid handle > ($err = Win32::RASE::GetLastError) != 6 and die > Win32::RASE::FormatMessage($err); > exit; > > The above code goes into a while loop and constantly checks for > the internet connection and prints connected or disconnected as > appropriate > > Now my question is how do I use this loop in Win32 GUI well, it depends on the design of your application. basically, the Right Way is to use DoEvents. DoEvents is similar to Dialog, in the sense that it looks for keypresses, mouse clicks, etc. and fires the appropriate event(s). the big difference is that DoEvents does not loop, like Dialog, until it receives a termination message. instead, if there's nothing to process, DoEvents returns immediately. you can call DoEvents inside the loop like this: while ( ($status, $status_text) = RasGetConnectStatus($hrasconn) ) { if ($status != $old_status) { print "$status: $status_text\n"; $old_status = $status; } sleep ($@ ? 1 : 0.01); $MainWindow->DoEvents(); } this way your application can have a 'Stop' button that may, for example, break the loop (not *immediately* responsive, but better than nothing :-). the loop could be embedded in an event sub (for example, StartCheck_Click), or you can have no Win32::GUI::Dialog at all, so that the above loop is the real 'core' of the script. as I said, it depends on the design of your application. if this is not clear, please elaborate a bit more about the program you're trying to write. cheers, Aldo __END__ $_=q,just perl,,s, , another ,,s,$, hacker,,print; _______________________________________________ Perl-Win32-GUI-Users mailing list Per...@li... http://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users |
From: Nahum M. <Mar...@re...> - 2001-02-14 11:31:36
|
I do this too ... but it's close the window , and not all the script ... I can see the process yet in task manager (under NT4) off course , i hide the dos box so , i need kill the process ----- Original Message ----- From: "Aldo Calpini" <da...@pe...> To: "Nahum Marc" <per...@li...> Sent: Wednesday, February 14, 2001 12:01 PM Subject: Re: [perl-win32-gui-users] The cancel cross (upper right) in GUI > Nahum Marc wrote: > > How to manage the the cancel cross (upper right) in GUI to do > > an exit ? , not a window exit , but a script exit ... > > pick a sample script, anyone will do, from the samples directory > and study it. > > <HINT> > supposing your window is named Window, add this line to your > script: > sub Window_Terminate { -1 } > </HINT> > > > cheers, > Aldo > > __END__ > $_=q,just perl,,s, , another ,,s,$, hacker,,print; > > > > _______________________________________________ > Perl-Win32-GUI-Users mailing list > Per...@li... > http://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users > |
From: Aldo C. <da...@pe...> - 2001-02-14 10:56:19
|
Nahum Marc wrote: > How to manage the the cancel cross (upper right) in GUI to do > an exit ? , not a window exit , but a script exit ... pick a sample script, anyone will do, from the samples directory and study it. <HINT> supposing your window is named Window, add this line to your script: sub Window_Terminate { -1 } </HINT> cheers, Aldo __END__ $_=q,just perl,,s, , another ,,s,$, hacker,,print; |
From: Aldo C. <da...@pe...> - 2001-02-14 10:39:19
|
christopher sagayam wrote: > I might be slow to learn but > Actually what Im concerned about is the while loop > How do I get out of the while loop ? > > while ( ($status, $status_text) = RasGetConnectStatus($hrasconn) ) { > } > > once the control goes into this loop how it is going to get out ? > Or are these kinds of daemons possible in Win32::GUI ? as I already said, it depends on your application. and I also add, it depends on your Perl programming style :-) a possible way could be: $stay_in_loop = 1; while ( $stay_in_loop ) { ($status, $status_text) = RasGetConnectStatus($hrasconn) or $stay_in_loop = 0; # ...body of the loop... $MainWindow->DoEvents(); } at this point, you could have for example a 'Stop' button which can control the loop like this: sub Stop_Click { $stay_in_loop = 0; } but you may prefer a different approach... cheers, Aldo __END__ $_=q,just perl,,s, , another ,,s,$, hacker,,print; |
From: Nahum M. <Mar...@re...> - 2001-02-14 10:25:49
|
How to manage the the cancel cross (upper right) in GUI to do an exit ? = , not a window exit , but a script exit ... |
From: christopher s. <chr...@ya...> - 2001-02-14 10:23:20
|
I might be slow to learn but Actually what Im concerned about is the while loop How do I get out of the while loop ? while ( ($status, $status_text) = RasGetConnectStatus($hrasconn) ) { } once the control goes into this loop how it is going to get out ? Or are these kinds of daemons possible in Win32::GUI ? chris ----- Original Message ----- From: <Kev...@Al...> To: <chr...@ya...> Cc: <per...@li...> Sent: Wednesday, February 14, 2001 3:22 PM Subject: Re: [perl-win32-gui-users] looping in win32 GUI Chris, I guess what you want to do is have a status window on which you can display the status text from the RASE call? If that's the case you can do something like this use Win32::GUI; my $Win = new Win32::GUI::Window( -left => 341, -top => 218, -width => 300, -height => 86, -name => "Win", -text => "RAS Status" ); $Win->AddLabel( -text => " ", -name => "Label", -left => 5, -top => 5, -width => 280, -height => 48, ); sub display { # Update status text my $text=shift; $Win->Show(); $Win->BringWindowToTop(); $Win->Refresh(); $Win->Label->Text($text); $Win->Label->Update(); } and use display instead of the print in your code sample. If you have other windows that you want to run in the foreground you might want to consider not using $Win->BringWindowToTop(). Hope that helps. Kev. chr...@ya... on 14/02/2001 13:29:22 To: per...@li... @ INTERNET cc: Subject: [perl-win32-gui-users] looping in win32 GUI $|=1; use Win32::RASE; eval "use Time::HiRes qw(sleep)"; $hrasconn = (RasEnumConnections())[1]; $old_status = -1; while ( ($status, $status_text) = RasGetConnectStatus($hrasconn) ) { if ($status != $old_status) { print "$status: $status_text\n"; $old_status = $status; } sleep ($@ ? 1 : 0.01); } # error 6 - Invalid handle ($err = Win32::RASE::GetLastError) != 6 and die Win32::RASE::FormatMessage($err); exit; The above code goes into a while loop and constantly checks for the internet connection and prints connected or disconnected as appropriate Now my question is how do I use this loop in Win32 GUI suppose I use the above loop as it is control , will NOT be transferred to any other part of the program... I know that Win32::GUI::Dialog(); actually goes into an indefinite loop looking for keypresses etc How can I integrate the while loop also into theWin32::GUI::Dialog(); loop ? hope Im clear with my question if NOT I will elaborate Thanks chris www.perl-resume.com _______________________________________________ Perl-Win32-GUI-Users mailing list Per...@li... http://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users |
From: Aldo C. <da...@pe...> - 2001-02-14 10:12:13
|
christopher sagayam wrote: > $|=1; > use Win32::RASE; > eval "use Time::HiRes qw(sleep)"; > $hrasconn = (RasEnumConnections())[1]; > $old_status = -1; > while ( ($status, $status_text) = RasGetConnectStatus($hrasconn) ) { > if ($status != $old_status) { > print "$status: $status_text\n"; > $old_status = $status; > } > sleep ($@ ? 1 : 0.01); > } > # error 6 - Invalid handle > ($err = Win32::RASE::GetLastError) != 6 and die > Win32::RASE::FormatMessage($err); > exit; > > The above code goes into a while loop and constantly checks for > the internet connection and prints connected or disconnected as > appropriate > > Now my question is how do I use this loop in Win32 GUI well, it depends on the design of your application. basically, the Right Way is to use DoEvents. DoEvents is similar to Dialog, in the sense that it looks for keypresses, mouse clicks, etc. and fires the appropriate event(s). the big difference is that DoEvents does not loop, like Dialog, until it receives a termination message. instead, if there's nothing to process, DoEvents returns immediately. you can call DoEvents inside the loop like this: while ( ($status, $status_text) = RasGetConnectStatus($hrasconn) ) { if ($status != $old_status) { print "$status: $status_text\n"; $old_status = $status; } sleep ($@ ? 1 : 0.01); $MainWindow->DoEvents(); } this way your application can have a 'Stop' button that may, for example, break the loop (not *immediately* responsive, but better than nothing :-). the loop could be embedded in an event sub (for example, StartCheck_Click), or you can have no Win32::GUI::Dialog at all, so that the above loop is the real 'core' of the script. as I said, it depends on the design of your application. if this is not clear, please elaborate a bit more about the program you're trying to write. cheers, Aldo __END__ $_=q,just perl,,s, , another ,,s,$, hacker,,print; |
From: <Kev...@Al...> - 2001-02-14 09:54:34
|
Chris, I guess what you want to do is have a status window on which you can display the status text from the RASE call? If that's the case you can do something like this use Win32::GUI; my $Win = new Win32::GUI::Window( -left => 341, -top => 218, -width => 300, -height => 86, -name => "Win", -text => "RAS Status" ); $Win->AddLabel( -text => " ", -name => "Label", -left => 5, -top => 5, -width => 280, -height => 48, ); sub display { # Update status text my $text=shift; $Win->Show(); $Win->BringWindowToTop(); $Win->Refresh(); $Win->Label->Text($text); $Win->Label->Update(); } and use display instead of the print in your code sample. If you have other windows that you want to run in the foreground you might want to consider not using $Win->BringWindowToTop(). Hope that helps. Kev. chr...@ya... on 14/02/2001 13:29:22 To: per...@li... @ INTERNET cc: Subject: [perl-win32-gui-users] looping in win32 GUI $|=1; use Win32::RASE; eval "use Time::HiRes qw(sleep)"; $hrasconn = (RasEnumConnections())[1]; $old_status = -1; while ( ($status, $status_text) = RasGetConnectStatus($hrasconn) ) { if ($status != $old_status) { print "$status: $status_text\n"; $old_status = $status; } sleep ($@ ? 1 : 0.01); } # error 6 - Invalid handle ($err = Win32::RASE::GetLastError) != 6 and die Win32::RASE::FormatMessage($err); exit; The above code goes into a while loop and constantly checks for the internet connection and prints connected or disconnected as appropriate Now my question is how do I use this loop in Win32 GUI suppose I use the above loop as it is control , will NOT be transferred to any other part of the program... I know that Win32::GUI::Dialog(); actually goes into an indefinite loop looking for keypresses etc How can I integrate the while loop also into theWin32::GUI::Dialog(); loop ? hope Im clear with my question if NOT I will elaborate Thanks chris www.perl-resume.com _______________________________________________ Perl-Win32-GUI-Users mailing list Per...@li... http://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users |
From: christopher s. <chr...@ya...> - 2001-02-14 03:05:25
|
$|=1; use Win32::RASE; eval "use Time::HiRes qw(sleep)"; $hrasconn = (RasEnumConnections())[1]; $old_status = -1; while ( ($status, $status_text) = RasGetConnectStatus($hrasconn) ) { if ($status != $old_status) { print "$status: $status_text\n"; $old_status = $status; } sleep ($@ ? 1 : 0.01); } # error 6 - Invalid handle ($err = Win32::RASE::GetLastError) != 6 and die Win32::RASE::FormatMessage($err); exit; The above code goes into a while loop and constantly checks for the internet connection and prints connected or disconnected as appropriate Now my question is how do I use this loop in Win32 GUI suppose I use the above loop as it is control , will NOT be transferred to any other part of the program... I know that Win32::GUI::Dialog(); actually goes into an indefinite loop looking for keypresses etc How can I integrate the while loop also into theWin32::GUI::Dialog(); loop ? hope Im clear with my question if NOT I will elaborate Thanks chris www.perl-resume.com |
From: Keith K. <kki...@st...> - 2001-02-12 19:36:09
|
The Perl code below will cause an access violation. Uncommenting the -name parameter will fix it. Took a while to figure this out. The offending line is in GUI.XS, Create(), line 4512: strcpy( (perlud->szWindowName), perlcs.szWindowName); Is this the proper mailing list to report bugs on? -Keith. --cut here--cut here--cut here--cut here--cut here--cut here--cut here--cut here--cut here-- use strict; use Win32::GUI; $wndMain = Win32::GUI::Window->new( -name => 'wndMain', -title => 'pbLaunch', -width => 600, -height => 400 ); $wndStatus = $wndMain->AddStatusBar( ## -name => 'wndStatus', -width => $wndMain->ScaleWidth ); |
From: Ludvig af K. <kli...@ho...> - 2001-02-12 19:29:24
|
I don't know much about the guts of Win32::GUI (or Win32 in general, or POE for that matter), but would a combination of POE and Win32::GUI be successful, or is Win32::GUI not stable enough yet? Or simply not constructed for that sort of thing? To me the possibilities seem great, but maybe I'm just following the hype, being too enthusiastic about POE. My monitoring example is, namely, just an example. It does by the way use quite a lot of HTTP specific stuff with cookies and redirects, so that's why I chose to implement the networking with a module instead of making it neatly non-blocking. -Ludde Reini Urban wrote: > > If Win32::GUI would be thread-safe :) > POE is for sure a very nice abstraction layer for process management. > > I would also recommend reading an ordinary win32 sdk book, the charles petzold > "Programming Windows" probably. http://www.relisoft.com/win32/ > if you borrow it from a library you'll get the cd, where the complete text > is in chm! (4mb) > This book would answer 80% if the questions here, btw. > > The very good perl cookbook has some good descriptions on process management, > blocking, locks, threads, forks and alarms. > There exists also a fulltext version in html. > I don't fully understand this yet. > > but i think that your web monitor example is covered in the cookbook. > > Ludvig af Klinteberg schrieb: > > I just read some about POE (Perl Object Environment - > > http://poe.perl.org), and it seems really interesting. I had the idea > > that by combining POE and Win32::GUI you could perhaps create a UI > > program that doesn't freeze whenever it's doing something time > > consuming. (e.g. sending/receiving data over a network) > > > > Some time ago I wrote a small program using Win32::GUI and > > LWP::UserAgent that downloaded a web page every X minutes and checked if > > it had been updated, and if it had the program popped up a window on the > > screen. The only problem was that it was impossible to interact with the > > program while it was downloading this (quite large) page from the > > (rather slow) server. The idea struck me that maybe rewriting the whole > > thing using POE might solve my troubles? As I said, I have no experience > > with POE, but if it could be successfully combined with Win32::GUI I > > would definitely look into it. So, can it be done? Has anyone with POE > > knowledge tried it? > -- > Reini Urban > http://xarch.tu-graz.ac.at/home/rurban/ > > _______________________________________________ > Perl-Win32-GUI-Users mailing list > Per...@li... > http://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users |
From: Aldo C. <da...@pe...> - 2001-02-12 10:47:24
|
Erick J. Bourgeois wrote: >> sorry, but where did you got this syntax? > > From the documentation in FileOp module. oh, well, FileOp != Win32::GUI :-) cheers, Aldo __END__ $_=q,just perl,,s, , another ,,s,$, hacker,,print; |
From: Erick J. B. <er...@e-...> - 2001-02-12 10:35:54
|
> sorry, but where did you got this syntax? From the documentation in FileOp module. erick never stop questioning www.jeb.ca ----- Original Message ----- From: Aldo Calpini <da...@pe...> To: Erick J. Bourgeois <per...@li...> Sent: Monday, February 12, 2001 10:47 AM Subject: Re: [perl-win32-gui-users] SaveAsDialog > Erick J. Bourgeois wrote: > > Has anyone had success using the SaveAsDialog? > > > > I'm using the SaveAsDialog in the following way: > > > > my %param = (title => "SaveAs", > > filters=>{'Filter 1' => '*.txt;*.doc', 'Filter 2' > > =>'*.pl;*.pm'}); > > my $file = SaveAsDialog %param, "foo.txt"; > > sorry, but where did you got this syntax? > > try this: > > my $file = Win32::GUI::GetSaveFileName( > -title => "SaveAs", > -filter => [ > "Filter 1" => "*.txt;*.doc", > "Filter 2" => "*.pl;*.pm", > ], > -file => "foo.txt", > ); > > > cheers, > Aldo > > __END__ > $_=q,just perl,,s, , another ,,s,$, hacker,,print; > > > > _______________________________________________ > Perl-Win32-GUI-Users mailing list > Per...@li... > http://lists.sourceforge.net/lists/listinfo/perl-win32-gui-u sers > |
From: Aldo C. <da...@pe...> - 2001-02-12 09:42:20
|
Erick J. Bourgeois wrote: > Has anyone had success using the SaveAsDialog? > > I'm using the SaveAsDialog in the following way: > > my %param = (title => "SaveAs", > filters=>{'Filter 1' => '*.txt;*.doc', 'Filter 2' > =>'*.pl;*.pm'}); > my $file = SaveAsDialog %param, "foo.txt"; sorry, but where did you got this syntax? try this: my $file = Win32::GUI::GetSaveFileName( -title => "SaveAs", -filter => [ "Filter 1" => "*.txt;*.doc", "Filter 2" => "*.pl;*.pm", ], -file => "foo.txt", ); cheers, Aldo __END__ $_=q,just perl,,s, , another ,,s,$, hacker,,print; |
From: Aldo C. <da...@pe...> - 2001-02-12 09:37:40
|
Erick J. Bourgeois wrote: > I wish to prevent the user from choosing more than one item > in a Listview and since I didn't find an option > for -multisel, like in a ListBox, I have attempted to > achieve this through the ItemClick event for a ListView. > > sub ListView_ItemClick { > if ($Win->ListView->SelectCount() > 1) { > Win32::MsgBox("You can not pick more than one > item!", 48, "Choose Only One"); > $Win->ListView->Select(0); > return; > } > } > > This displays the MsgBox great the first time, however it > then loops back and displays it again, it fact, I believe it > displays the MsgBox 2**(amount of selected items) times (ie. > 2 to the power of). As you may see I tried Selecting the > first item so the sub won't be called again. Any ideas? yes, doing a: $Win->ListView->Select(0); really fires an ItemClick event on the ListView, so you're in a loop. you can use the -singlesel option on the ListView to achieve what you want. cheers, Aldo __END__ $_=q,just perl,,s, , another ,,s,$, hacker,,print; |
From: Reini U. <ru...@x-...> - 2001-02-11 19:42:42
|
If Win32::GUI would be thread-safe :) POE is for sure a very nice abstraction layer for process management. I would also recommend reading an ordinary win32 sdk book, the charles petzold "Programming Windows" probably. http://www.relisoft.com/win32/ if you borrow it from a library you'll get the cd, where the complete text is in chm! (4mb) This book would answer 80% if the questions here, btw. The very good perl cookbook has some good descriptions on process management, blocking, locks, threads, forks and alarms. There exists also a fulltext version in html. I don't fully understand this yet. but i think that your web monitor example is covered in the cookbook. Ludvig af Klinteberg schrieb: > I just read some about POE (Perl Object Environment - > http://poe.perl.org), and it seems really interesting. I had the idea > that by combining POE and Win32::GUI you could perhaps create a UI > program that doesn't freeze whenever it's doing something time > consuming. (e.g. sending/receiving data over a network) > > Some time ago I wrote a small program using Win32::GUI and > LWP::UserAgent that downloaded a web page every X minutes and checked if > it had been updated, and if it had the program popped up a window on the > screen. The only problem was that it was impossible to interact with the > program while it was downloading this (quite large) page from the > (rather slow) server. The idea struck me that maybe rewriting the whole > thing using POE might solve my troubles? As I said, I have no experience > with POE, but if it could be successfully combined with Win32::GUI I > would definitely look into it. So, can it be done? Has anyone with POE > knowledge tried it? -- Reini Urban http://xarch.tu-graz.ac.at/home/rurban/ |
From: Ludvig af K. <kli...@ho...> - 2001-02-11 19:05:23
|
I just read some about POE (Perl Object Environment - http://poe.perl.org), and it seems really interesting. I had the idea that by combining POE and Win32::GUI you could perhaps create a UI program that doesn't freeze whenever it's doing something time consuming. (e.g. sending/receiving data over a network) Some time ago I wrote a small program using Win32::GUI and LWP::UserAgent that downloaded a web page every X minutes and checked if it had been updated, and if it had the program popped up a window on the screen. The only problem was that it was impossible to interact with the program while it was downloading this (quite large) page from the (rather slow) server. The idea struck me that maybe rewriting the whole thing using POE might solve my troubles? As I said, I have no experience with POE, but if it could be successfully combined with Win32::GUI I would definitely look into it. So, can it be done? Has anyone with POE knowledge tried it? I think that's what I meant... -Ludde |
From: Erick J. B. <er...@e-...> - 2001-02-11 19:02:48
|
I wish to prevent the user from choosing more than one item in a Listview and since I didn't find an option for -multisel, like in a ListBox, I have attempted to achieve this through the ItemClick event for a ListView. sub ListView_ItemClick { if ($Win->ListView->SelectCount() > 1) { Win32::MsgBox("You can not pick more than one item!", 48, "Choose Only One"); $Win->ListView->Select(0); return; } } This displays the MsgBox great the first time, however it then loops back and displays it again, it fact, I believe it displays the MsgBox 2**(amount of selected items) times (ie. 2 to the power of). As you may see I tried Selecting the first item so the sub won't be called again. Any ideas? erick never stop questioning www.jeb.ca |
From: Moore, L. <Lar...@tf...> - 2001-02-10 22:01:58
|
Is it possible to change the font/background attributes for each string added to a listbox, say based on the length of the string? Or is there a better object for something such as this? Larry |
From: <pau...@or...> - 2001-02-09 22:07:49
|
David I *BELIEVE* fork() is supported in Perl 5.6 on Win32 in an emulated form, but I'm 150 miles away from my documentation and only have a 9600 baud mobile to connect to the web over so I can't check ! It wasn't supported in older builds. Cheers Paul ******************************************************************************* Important. This E-mail is intended for the above named person and may be confidential and/or legally privileged. If this has come to you in error you must take no action based on it, nor must you copy or show it to anyone; please inform the sender immediately. ******************************************************************************* |
From: Tom A. <to...@yt...> - 2001-02-09 19:57:31
|
David Kuo said: > A question might be stupid. Is the fork() working in NT or Win98? > I tried it before but failed with message the function is not > supported by the OS. I think you need Perl 5.6 for this to work. In ActiveState speak, that is the 600 series of builds. And yes, using ActiveState build 623, the fork works on both NT and 98. --- Tom Tom Allebrandi to...@yt... |
From: Kuo D. <dk...@or...> - 2001-02-09 19:08:48
|
A question might be stupid. Is the fork() working in NT or Win98? I tried it before but failed with message the function is not supported by the OS. Thanks, David -----Original Message----- From: Tom Allebrandi [mailto:to...@yt...] Sent: Friday, February 09, 2001 1:34 PM To: per...@li... Subject: [perl-win32-gui-users] Interesting behavior I'm not sure if I should post this on this list or over on the Perl Win32 Users list. Under Win32::GUI version 502 and ActiveState build 623, the following script results in an access violation under NT 4 and an invalid page fault under Win98. NT is only telling me a memory address where the problem is occurring. Win98 claims that the invalid page fault is in Perl56.DLL. #! perl use Win32::GUI; # ** 1 ** fork(); # ** 2 ** # # The $' (or the $`) var has to be present in order to cause the crash, but # since it's not defined, use the "if (0)" to avoid interpreting it # if (0) { $'; # ** 3 ** } If you take out any of the lines marked "# ** n **" the problem goes away! At one point, I had a print("Goodbye\n"); as the last statement in the script. I got both of them (one from each branch of the fork()) which suggests that the problem is occurring in the rundown of Perl itself. If I had to guess, something is not getting cloned properly during the fork() and it's invalid when the GUI destructor(s) get invoked at termination. Cute huh? --- Tom Tom Allebrandi to...@yt... _______________________________________________ Perl-Win32-GUI-Users mailing list Per...@li... http://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users |