27;re appropriately licensed if you plan to distribute outside of your
>organization)
>
>
>
>-Original Message-
>From: Timothy Johnson
>Sent: Wednesday, July 26, 2006 8:21 AM
>To: 'Michael D. Smith'; perl-win32-users@listserv.ActiveState.com
>Subject:
g C book and an advanced C book.
Apparently it's in the middle-ing C book :)
ms
At 06:34 AM 7/26/2006, you wrote:
>Michael D. Smith wrote:
> > Okay, tested just copying the Perl folder to E drive and it worked.
> >
> > My CD drives are G and H but a CD could be any drive
Okay, tested just copying the Perl folder to E drive and it worked. I
uninstalled perl and deleted the folders from my hard drive for testing
purposes, burned perl folder onto the CD, deleted eg and html folders for
space but it wasn't really necessary, there's plenty of room.
My CD drives ar
Lynn, Tom
>Sent: Tuesday, July 25, 2006 11:14 AM
>To: 'Michael D. Smith'
>Subject: RE: PERL on a CD
>
>Why not just make your script an standalone executable program?
>
___
Perl-Win32-Users mailing list
Perl-Win32-Users@listser
Is it possible to burn PERL and a script onto a CD and execute it from
there without installing perl on the host computer?
There would be nothing in the registry. The path to perl.exe would have to
be included for the script to execute -- but beyond that, I'm a blank.
Any thoughts appreciated.
At 09:45 PM 7/16/2006, you wrote:
>Eric Edwards wrote:
>
> > $Bill wrote:
> > When you post code, post a small complete failing snippet with any input
> > and output examples:
> > use strict;
> > use warnings;
> > use Data::Dumper; $Data::Dumper::Indent=1; $Data::Dumper::Sortkeys=1;
> > my @array
Thanks again everyone. Data::Dumper was the "key" to the whole thing.
The array was loaded from a file. All the keys (and data) had newlines on
the end. When I asked for a key without a newline -- it wasn't there -- and
I just assumed the statement was a little to cute -- but not for PERL :)
m
At 08:03 PM 7/16/2006, Charles K. Clarkson wrote:
>Michael D. Smith wrote:
>
>: This is what I want to do:
>:
>: %hash = @array;
>:
>: But it don't work :)
>
>Define "it don't work".
There is nothing in the hash after execution. It's
This is what I want to do:
%hash = @array;
But it don't work :)
Every other array element is a key and every other one is data. A loop,
could be done, but this every other one thing could get complicated.
Must be an easy way.
ms
___
Perl-Win32-
At 12:30 PM 3/8/2006, Jeff Griffiths wrote:
Chris Wagner wrote:
Did anyone else also just receive a boat load of old messages from the list?
I've got about 25 and more coming. They go back to October. And the really
funny thing about it is they're all from threads I participated in. I
che
Is there a right way/best way to check for an internet connection?
Now I'm using LWP simple to retrieve a webpage, if that fails, just assuming no
connection. It's fast when it works. I like fast, but that assumption is
not always
correct and causes the script to fail inelegantly when it isn't.
At 10:30 AM 7/18/2004, you wrote:
So what doesn't the list manager simply make "Out of Office" a forbidden
sequence in a subject or body, and trash such emails?
I already suggested that to AS and got no response. It seems it should be
easy enough and I too could live with it. In fact, I would app
When the Camel book says, "We recommend you start with the perlxstut(3)
manpage," what is that, and where could I find it?
I'm on a Windows 2000 OS. That looks like a UNIX manual reference, and
obviously being on windozes I have no *nix manual, and "man" doesn't work
from the command line, so w
I have no idea if its related but I too have problems (not the same problem
mine reboots) if I try run a loop more than somewhere between 16 million
and 17 million times.
I thought it was my 'puter (it's 2 years old now, probably getting creaky
in the joints), or OS (Windoze 2K) but I guess it
I'm looking for opinions on, is this a PERL error or is my 'puter getting
ready for the old 'puter's home.
I have two perl scripts. One dials the phone, one sets the time -- both
work individually no problem.
Until I got the idea to tack the one that sets the time onto the end of the
one that
I too have noticed that 'system' commands that worked on win98, don't on
win2000 pro.
For instance, I could execute a shortcut (using start.exe), that I can find
no way to do on 2k.
This:
system("cmd /c dir /s");
does work on 2k. But this syntax:
system('cmd', '/c', 'dir', '/s');
I have fou
With a little trial and error (mostly error:), I finally got this to work.
system ("C:\\winnt\\system32\\rasdial.exe", "MyDUNConnectionName",
"[EMAIL PROTECTED]", "password") == 0 or die "MyDie1
syscmd failed: $?";
Now, I wonder if the "normal" dialup networking error
Anyone know the "proper" way to activate dialup networking on win2000?
Using PERL of course. I can double click it no problem:)
When I try what used to work on 98, it fails, and locks the system up so
bad that it takes a long time to shut down for a reboot.
Network and dialup connections is o
Somehow, I have no idea how, my @INC directory has been changed to E drive.
I have an E drive but perl is not on it, never has been. I use E
exclusively for my win2000 backup (.BKF) files. I don't think that info has
any bearing whatsoever on the problem but... since I have no idea what's
goi
I'm trying to get my perl script to run from the "command line" in my
battery backup.
It's sort of a command line. It's a textbox within the battery backup
software where you enter the program to run when the power goes off. It
works much like a command line, or at least it did on 98.
On my ol
I'm trying to make a program self-relocating; Drag and drop and it still
works. I have it working within a single drive/partition. Will it work
between drives/partitions if I search the registry for each occurrence of
the executable and change the drive letter -- or is it not that simple?
I'm t
> Where did you find the word student anywhere in the post ?...
> Nowhere did it say that you have to use spliti either.
I agree that nowhere did it "say" any of that. That was just me reading
between the lines -- except that she has said in the past that she's a
student (and the .edu on the emai
The thing is lorid is the student. If she's trying to use spliti
spliti(regexp patter,str,max split)
spliti(":",$my_Propellar_Data,15);
That's probably the assignment, and while There Is More Than One Way To Do
It, doing it "their way" is "the path" to student Nirvana.
I've never seen spliti bef
I want to use perl to get and parse search engine results (several if
possible) based on a variable keyword.
This can't be the first time anyone has wanted to do that. Question is,
does anyone know of any open source code, modules, whatever, just so I
don't have to recode the wheel? Mostly beca
>Try the one on my Tripod site.
I don't get it. It looks exactly like the one that came with win98 except
it's 3 times bigger.
Almost exactly anyway, the right click menu is not as extensive but the
functions can still be accessed from the buttons at the top.
So, why is it better (bigger) than
Well that definitely didn't send in plain format :)
So clearly it recognized it and performed some magic on it. Magic that in
this case I did NOT want.
Here's a try sent in "stylized" and without the original, which
it incorporated the first time making an even bigger mess, and I added
several
Opps sorry. That first mail was incomplete. I ran a test. Sent myself a
test email in both plain and html format. This header may also be needed:
Content-Type: multipart/alternative;
boundary="=_1906071==.ALT"
Then the extra tag already mentioned:
And those are the
I think, from looking at some of my stored emails with notepad, so I can
see the html, that what you need is this:
in front of the html tag, like so:
That's a guess but easy enough to test.
ms
From: "Frank Pikelner" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Subject: sending email in HTM
I had a problem once where the digit can be one or two, it was computer
generated and when the digit was one character, the space was two, so this
might be more reliable...
$line=~/[\w{3}
\w{3}\s{1,2}(\d{1,2})\s{1,2}(\d{4})\s{1,2}(\d\d):(\d\d):(\d\d)\]
And if it doesn't do that, it won't hurt
> Maybe I don't understand - or maybe I am just simply wrong - but the
system() command won't finish > until 'test.exe' has finished - so the loss
of the env vars won't matter, will it ?
It can be made to work either way.
system ('notepad.exe');
Doesn't return until notepad is closed.
system
Is there a "good" way to dial a modem with perl?
I'm using this now:
system ('C:\Windows\Command\start.exe',
'C:\Windows\Desktop\Highstream.net.lnk'):
And it starts Windows dialup networking, but I have no other control. Busy,
no connect, takes longer than normal, all cause a failure be
In these examples from recent mailings to the list
my $IE = Win32::OLE->GetActiveObject( 'WebBrowser.Application' );
my $Excel = Win32::OLE->GetActiveObject('Excel.Application')
Where can find a list of everything I can do with GetActiveObject in place
of 'webbrowser.application' and 'excel.appli
> This is perl, arrays start at zero, get used to it.
Right :)
And to perl you could add C, and it's offspring C++, and Fortran and COBOL
and JAVA(Script) and... I didn't even know there was one that didn't. I
know nothing of pascal but I believe:) pascal only offers the option of
starting w
The book says stay away from this, so I never messed with it (until now for
this test) but...
$[ = 1;
will change the first element of the array to one. On my box it actually
loads the first value read into both subscript zero and one, but accessing
the array starting from one would get the wh
You will recall the current mega-thread started not with a question but a
mention of "it" in jest. I hesitate to say "it" for obvious reason but
since everyone knows what "it" means, that may not matter. We may all be
doomed to lifetime filled with hundreds of emails about "it."
With that in mi
This file:
C:/Perl/html/faq/Windows/ActivePerl-Winfaq5.html#Signal_Handling
says, "Signals are unsupported by the Win32 API. The C Runtime provides
crude support for signals, but there are serious caveats, such as inability
to die() or exit() from a signal handler. Perl itself does not guarantee
Is there any way to use the Windows signals in PERL? As I understand it, in
a Window's program, there is a subroutine that's called when there is a
signal. But I don't see how that could be worked into a PERL program --
that executes linearly.
More basically, I want to send a kill command from
Sorry about the off topic post but viruses are a problem we all deal with
and I can't think of a better bunch of people to ask a computer question.
I've been asked several times, "I have the latest updated virus software.
Is it still possible I have a virus?" Any programmer knows the unfortunate
>Seeing as there are about 10^85 atoms in the universe
More realistically the number that can be addressed by 64 bits. It must be
64, you're already over the amount that can be addressed by 32 bits
(something just over 2 billion). 64 bits will address some exponent number
that you won't have to
that it's returning zero, means that it thinks it's working. Must?
be a system problem -- so where to go from here?
I might manage the two test lines in C, see if that works. It will prove
nothing but it might be interesting.
ms
At 04:23 PM 8/10/03, you wrote:
On Sun, 10 Aug 2003, Mi
I have this in a perl script that I thought sure was working:
$time = '12:01:02'; # make the test easy
system ('time', "$time") or warn "no joy";
Only now it's not working and I can find nothing. If it doesn't work, how
did I ever come to think it did, and if it did work, why not now?
Does thi
if (! defined ($value)) { print "1 value not defined\n";}
if ($value eq "") { print "2 Found empty string ($value)\n"; }
if ($value == 0) { print "3 Found a zero too ($value)\n"; }
$value = '';
if (defined ($value)) { print "4 value now is defined but null ($value)\n";}
if ($value eq "") { print "
Second try. Some how I messed up the first send (To those who know me not a
surprising event:) If you've received this twice my apologies.
Does anyone have a dial-up networking script that will intercept a busy
signal and try again?
I can start the connection from a script or a batch file but c
Does anyone know which Window's DLL makes, manages, manipulates shortcuts?
Or how I can find out?
ms
___
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
I'm not exactly sure what you want either, but no module is needed for:
system ('start', 'C:\progra~1\intern~1\IEXPLORE.exe', 'http://yahoo.com');
opening the browser to a certain URL on your desktop.
Bill's way will download the HTML into a file which is certainly useful
many times. I just d
That is two entirely separate things. Both of which I too have been trying
to figure out. As usual the documentation goes on at length, and yet
somehow never tells you what you want to know :)
In case someone wants to give an example, specifically, this page for the
HTML download:
http://tim
Many of the MS Windows screen savers have an option to specify a corner of
the screen that you can leave the mouse pointer in, and the screen saver
will never come on. Click the "settings" button, "General" tab.
I just tried it on mine. Doesn't seem to work. Wonderful, advise that
doesn't wor
It works for me on files but not directories and (of course:) -f and/or -d
don't work, which would allow you to check for that possibility, and
prevent it from happening. Which means it has very limited utility because
there's a always a "possibility" lurking in the code.
Is there any chance
ine of code they're proud of has a soft
spot in their heart for.
That would be all of us. Right? :)
ms
At 05:49 PM 8/1/02, you wrote:
> > -Original Message-
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED]]On Behalf Of
> > Michael D. Smith
> &g
If anyone starts getting page faults while running Perl (mine is Build 633
but I assume that matters little as this is actually a Windows problem)
check the date on C:\windows\system\oleaut32.dll. There is a new version
that's bad. Have you installed anything lately:)
I wish I could tell you
This page from the Win32 Perl book
http://www.mmg.vmei.acad.bg/perl/learn32/ch19_02.htm
Says, I should "use OLE;" (with the AS distribution) instead of:
use Win32::OLE;
I've tried both and either seems to work with this line (which isn't
exactly the same as the book's example):
$WshShell = n
Except of course reading through the documentation he says it's 32 bits
(left and right) and each side can go up to 65,536. Which completely
eliminates my theory of why it might be difficult. Not to mention it's been
so long since I used any binary I even missed how much 8 bits would hold --
I just tried out the C:\Perl\html\lib\B module
with this command line
perl -MO=CC,-mFoo,-oFoo.c Foo.pm
On this one line perl script
unless ($^O =~ /MSWin32/i) {die "Only Win32 OS";}
And that thing output 326 lines into Foo.c. I figured that getting the
Windows environmental variables
It looks to me like he's using 16 bits (8 for the left and 8 for the
right), and by shifting, keeping it all within one 16 bit "word." When
computers had 16k in memory, that kind of stuff was necessary, now -- IF
(big if) that is what he's doing -- it seems kind of silly. Of course,
doing tha
ge they're promoting to PERL).
Any point in the right direction will be greatly appreciated.
ms
At 15:56 6/22/02 -0400, you wrote:
>On Fri, 21 Jun 2002, Michael D. Smith wrote:
>
> >
> > I'm trying to automate the process of logging onto a company's proprietary
rint "1..2\n"; }
END {print "not ok 1\n" unless $loaded;}
use Win32::API;
$loaded = 1;
print "ok 1\n";
# End of black magic.
$GetPID = new Win32::API("kernel32", "GetCurrentProcessId", "", "N");
$PID = $GetP
This is a small thing but it's annoying me. I've been using a gobal
variable inside a subroutine, which you're not supposed to have to do, or
get a warning, which isn't fatal either but I don't like it.
Basically, I want a first time switch.
I can do that with a gobal variable like this:
$fi
When you find it you have to break out of there. Maybe you left out some
code you thought was obvious but what you are showing me needs a way out.
Label1:
foreach $line1 (@array1){
foreach $line2 (@array2) {
if ($line1 eq $line2) {print ...; next Label1; } # actually you're
no
I just tried:
useWin32::OLE;
And I got two errors, package strict wasn't found nor was package vars. A
search of C drive found neither on my computer, so they weren't just not
found, they aren't here.
Does this happen a lot, that packages that are included in the ActiveState
distribution, c
Very interesting. I've used system before, without anything where the
'Start' is. Without commands, it waits and returns only after the called
program is closed, in this case notepad:
system ('C:\\Windows\\Notepad.exe ', 'C:\\Windows\\TEMP\\TextFile.txt') == 0
or die "Mysystemdie $
There is the example from the Camel book for putting in commas,
1 while s/(\d)(\d\d\d)(?!\d)/$1,$2/;
which can easily be modified from three and comma, to two and a space:
1 while s/(\d)(\d\d)(?!\d)/$1 $2/;
Which also leaves odd ones on the left. The previous solution put them on
the right.
61 matches
Mail list logo