Re: Benchmark Error

2002-02-14 Thread Sisyphus
- Original Message - From: "Dirk Bremer" <[EMAIL PROTECTED]> To: "'Perl Win32 Users Mailing List'" <[EMAIL PROTECTED]> Sent: Friday, February 15, 2002 7:41 AM Subject: Benchmark Error > When I benchmark using this code: > > { > sub test1($) > { > my $self = shift; >

RE: OLE Functions

2002-02-14 Thread Toby Stuart
u can use M$ Word or Excel's object browser. open Word hit ALT + F11 goto tools and select References select the typelib you require open the object browser (view->Object Browser) or F2 ... and select the class from the drop down (top left) hth t0by -Original Message- From: Richard

OLE Functions

2002-02-14 Thread Richard A. Evans
I have seen (and have written) perl code such as: use Win32::OLE; # use existing instance if Excel is already running eval {$ex = Win32::OLE->GetActiveObject('Excel.Application')}; die "Excel not installed" if $@; unless (defined $ex) { $ex = Win32::OLE->new('Excel.Application', su

RE: Moon phases in Perl

2002-02-14 Thread Richard A. Evans
> Any known moon calculator for the moon phases (moon calendar). Ideas appreciated. I've never used it, but you might look at Astro::Moonphase Regards, Rick ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveSt

Re: Zero-suppression Regex

2002-02-14 Thread $Bill Luebkert
Dirk Bremer wrote: > Here is a quicker version of the zero-suppression routine that will also float a >leading sign character: > > sub ZeroSuppress2($) > { > my $self = shift; > > # Return if the argument is less than two digits. > return($self) if (length($self

Socket with XML Request

2002-02-14 Thread karthikeyan
Hi Everybody,     I need help on this :   1)   Generate an XML request. 2)   Open a TCP socket to www.somename.com on port 100. 3)   Strip out any carriage returns or linefeeds from my request. 4)   Send my request as plain ASCII text. Should send a CrLf when done. 5)  

RE: Moon phases in Perl

2002-02-14 Thread Vroom, Tim
Title: RE: Moon phases in Perl Check out pom from the Perl Power Tools project. http://www.perl.com/language/ppt/src/pom/pom.caputo -Original Message- From: Roman @ Melihhov [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 14, 2002 4:14 PM To: '[EMAIL PROTECTED]' Subject: Moon p

Moon phases in Perl

2002-02-14 Thread Roman @ Melihhov
Hey, Any known moon calculator for the moon phases (moon calendar). Ideas appreciated. Roman. ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Re: Benchmark Error

2002-02-14 Thread Nick Pomponio
Dirk, The 'timethese' routine is expecting the code to be passed as either a string or as a ref to a sub. You seem to be passing the return value from a single invocation of each of your two subs. Try using this statement instead: timethese(100,{ 'regex' => q, 'substri

Re: Benchmark Error

2002-02-14 Thread Jeffrey
I am assuming that this is the whole code. Correct me if this is not the case. If it is, then why do you have the outermost {}'s? But I don't get the error either with or without the extra braces. --- Dirk Bremer <[EMAIL PROTECTED]> wrote: > When I benchmark using this code: > > { > sub te

Benchmark Error

2002-02-14 Thread Dirk Bremer
When I benchmark using this code: { sub test1($) { my $self = shift; return($self =~ s/^\s+//); } sub test2($) { my $self = shift; while (substr($self,0,1) eq ' ') {$self = substr($self,1);} return($self); } use Benchmark;

Re: Zero-suppression Regex

2002-02-14 Thread Dirk Bremer
Here is a quicker version of the zero-suppression routine that will also float a leading sign character: sub ZeroSuppress2($) { my $self = shift; # Return if the argument is less than two digits. return($self) if (length($self) < 2); # Search for a embed

RE: perl/TK Label widget not updating quirky problem????

2002-02-14 Thread John V. Pataki
some ideas not sure exactly what your issue is... but... sub gui_update { #... your changes to text and textvariables based on criteria (if this then that,etc) $lb->update; } # end sub $lb->repeat(100,\&gui_update); # 100 milliseconds -Original Message- From: [EMAIL PROTECT

RE: What the heck is idletasks()? [was: Changing the Icon in a Perl/T k toplevel/mainwindow...]

2002-02-14 Thread Dunnigan,Jack [Edm]
> -Original Message- > From: Adrian Stovall [mailto:[EMAIL PROTECTED]] > Sent: Thursday, February 14, 2002 10:24 AM > To: [EMAIL PROTECTED] > Subject: What the heck is idletasks()? [was: Changing the Icon in a > Perl/T k toplevel/mainwindow...] > What is idletasks? More specifically, wh