[17843] in Perl-Users-Digest
Perl-Users Digest, Issue: 3 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Fri Jan 5 18:25:32 2001
Date: Fri, 5 Jan 2001 15:25:11 -0800 (PST)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <978737111-v10-i3@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Fri, 5 Jan 2001 Volume: 10 Number: 3
Today's topics:
Re: Remote Controll other windows software by Perl <neil@alaweb.com>
Re: Remote Controll other windows software by Perl <founder@pege.org>
Re: Remote Controll other windows software by Perl <juex@deja.com>
Re: Remote Controll other windows software by Perl <juex@deja.com>
Re: Remote Controll other windows software by Perl <founder@pege.org>
Re: Segmented Mac OS X dev tools (Matthew T. Russotto)
Re: Segmented Mac OS X dev tools (Ilya Zakharevich)
Re: Segmented Mac OS X dev tools (Peter Seebach)
Re: socket in perl, help!! <b0l4549@cs.tamu.edu>
Re: Sorting a Text file Database with perl (Honza Pazdziora)
Re: Troubleshooting flock failure (Honza Pazdziora)
Re: Uninstalling CPAN modules <khera@kciLink.com>
Using variable with metacharacters in regex menditto@my-deja.com
Re: Using variable with metacharacters in regex (Greg Bacon)
Re: V V easy Question I hope! (Brandon Metcalf)
Version of AS/400 perl. <lacroix_andre@emc.com>
Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Fri, 5 Jan 2001 13:50:43 -0600
From: "Neil" <neil@alaweb.com>
Subject: Re: Remote Controll other windows software by Perl
Message-Id: <t5c9ce5iba3e6f@corp.supernews.com>
I would have a look at Win32::API or Win32::GUI to interact with the Win
programs. I have used these succesfully to create a perl script that
interacts with MSWindows windows. I have not posted an example as these have
all the documentation you need ... unless you also need the API docs from
Microsoft.
Good Luck,
Neil
"Mösl Roland" <founder@pege.org> wrote in message
news:3a55b42b$1$9846@SSP1NO25.highway.telekom.at...
> I would like to
>
> open Paint Shop Pro
> open some picture.jpg
> Save as some_picture_print.jpg
> resize, width=600
> Save as PARAMETER2.jpg
> resize, height=80
> Save as PARAMETER2_dir.jpg
>
> I had once under Windows 3.1 a script
> which converted several hundred pictures
> from a POV video into other format.
>
> So there should be something like this
> for Win 98 also where I can remote controll
> with Perl other Windows software.
>
> Is there any modul for this task?
>
> --
> Mösl Roland founder@pege.org
> http://www.pege.org clear targets for a confused civilization
> http://www.BeingFound.com web design starts at the search engine
>
>
>
>
>
------------------------------
Date: Fri, 5 Jan 2001 21:05:56 +0100
From: "Mösl Roland" <founder@pege.org>
Subject: Re: Remote Controll other windows software by Perl
Message-Id: <3a5628f9$0$24608@SSP1NO25.highway.telekom.at>
"Neil" <neil@alaweb.com> wrote in message
news:t5c9ce5iba3e6f@corp.supernews.com...
> I would have a look at Win32::API or Win32::GUI to interact with the Win
> programs. I have used these succesfully to create a perl script that
> interacts with MSWindows windows. I have not posted an example as these
have
> all the documentation you need ... unless you also need the API docs from
> Microsoft.
It's enough to know how to
start a program
maximize
simulate mouse or key strokes to activate a menu command
select an input element in a dialog box
enter key strokes into the dialog box
--
Mösl Roland founder@pege.org
http://www.pege.org clear targets for a confused civilization
http://www.BeingFound.com web design starts at the search engine
------------------------------
Date: Fri, 5 Jan 2001 12:57:55 -0800
From: "Jürgen Exner" <juex@deja.com>
Subject: Re: Remote Controll other windows software by Perl
Message-Id: <3a563553$1@news.microsoft.com>
"Mösl Roland" <founder@pege.org> wrote in message
news:3a5618c8$0$16006@SSP1NO25.highway.telekom.at...
> "Martien Verbruggen" <mgjv@tradingpost.com.au> wrote in message
> news:slrn95befk.t2v.mgjv@martien.heliotrope.home...
> > [comp.lang.perl removed. That group is long dead, please informa your
> > news admin]
> >
> > On Fri, 5 Jan 2001 12:47:18 +0100,
> > Mösl Roland <founder@pege.org> wrote:
> > > I would like to
> > >
> > > open Paint Shop Pro
> > > open some picture.jpg
> > > Save as some_picture_print.jpg
> > > resize, width=600
> > > Save as PARAMETER2.jpg
> > > resize, height=80
> > > Save as PARAMETER2_dir.jpg
> >
> > You will have to read the documentation on Paint Shop Pro to see how >
you
> > interact with it if you don't have a mouse.
>
> I have in web design always the same routine task.
>
> Save pictrue as name_print.jpg
> resize to 600 width
> Save picture as name.jpg
> resize to 80 height
> Save picture as name_dir.jpg
>
> Since it are several 1000 pictures, I do not like
> to click though the same idiot job again and again.
What you are looking for is Windows Scripting Host or you could also use
Visual Test (which comes with Visual Studio).
In either case, this has nothing to do with Perl any more.
jue
------------------------------
Date: Fri, 5 Jan 2001 12:59:02 -0800
From: "Jürgen Exner" <juex@deja.com>
Subject: Re: Remote Controll other windows software by Perl
Message-Id: <3a563596$1@news.microsoft.com>
"Bart Lateur" <bart.lateur@skynet.be> wrote in message
news:6a3c5tc3uholqi2au2b2d3emsuc8eopdk7@4ax.com...
> Ronald J.H. Rood wrote:
>
> >Question remains:
> >how can one run an application on a remote NT or windows machine ? I am
> >very interested in this.
The solution is Windows Terminal Server, but that has little to do with
Perl.
jue
------------------------------
Date: Fri, 5 Jan 2001 22:28:54 +0100
From: "Mösl Roland" <founder@pege.org>
Subject: Re: Remote Controll other windows software by Perl
Message-Id: <3a563c7b$0$25060@SSP1NO25.highway.telekom.at>
"Jürgen Exner" <juex@deja.com> wrote in message
news:3a563553$1@news.microsoft.com...
> "Mösl Roland" <founder@pege.org> wrote in message
> news:3a5618c8$0$16006@SSP1NO25.highway.telekom.at...
> > "Martien Verbruggen" <mgjv@tradingpost.com.au> wrote in message
> > news:slrn95befk.t2v.mgjv@martien.heliotrope.home...
> > > [comp.lang.perl removed. That group is long dead, please informa your
> > > news admin]
> > >
> > > On Fri, 5 Jan 2001 12:47:18 +0100,
> > > Mösl Roland <founder@pege.org> wrote:
> > > > I would like to
> > > >
> > > > open Paint Shop Pro
> > > > open some picture.jpg
> > > > Save as some_picture_print.jpg
> > > > resize, width=600
> > > > Save as PARAMETER2.jpg
> > > > resize, height=80
> > > > Save as PARAMETER2_dir.jpg
> > >
> > > You will have to read the documentation on Paint Shop Pro to see how >
> you
> > > interact with it if you don't have a mouse.
> >
> > I have in web design always the same routine task.
> >
> > Save pictrue as name_print.jpg
> > resize to 600 width
> > Save picture as name.jpg
> > resize to 80 height
> > Save picture as name_dir.jpg
> >
> > Since it are several 1000 pictures, I do not like
> > to click though the same idiot job again and again.
>
> What you are looking for is Windows Scripting Host or you could also use
> Visual Test (which comes with Visual Studio).
> In either case, this has nothing to do with Perl any more.
When I remember right,
PerlScript requires Windows Scripting Host
to use Perl as scripting language for Internet Explorer
I can not imagine, that there are so many Perl modules,
but nothing so simple like the old key and mouse recorder,
I had on Win 3.14
--
Mösl Roland founder@pege.org
http://www.pege.org clear targets for a confused civilization
http://www.BeingFound.com web design starts at the search engine
------------------------------
Date: Fri, 05 Jan 2001 19:12:25 GMT
From: russotto@wanda.vf.pond.com (Matthew T. Russotto)
Subject: Re: Segmented Mac OS X dev tools
Message-Id: <t0p56.2554$iK.297365@monger.newsread.com>
In article <933jhs$8e2$1@charm.magnus.acs.ohio-state.edu>,
Ilya Zakharevich <ilya@math.ohio-state.edu> wrote:
}[A complimentary Cc of this posting was sent to Peter Seebach
}<seebs@plethora.net>],
}who wrote in article <3a5542da$0$12802$3c090ad1@news.plethora.net>:
}> >> >> Assuming your perl script is not broken, I would assume that it's
}> >> >> because .gz files are binary, but cat is treating them as text.
}>
}> >> cat shouldn't care.
}>
}> >Of course it would. Remember C-z?
}>
}> "cat" is a Unix program
}
}??? What makes a program a "Unix program"?
}
}, and on Unix, ^Z is just another character that
}> can be part of any file, at any point in the file. (Or at least, the OP
}> was talking about using it on Unix.)
}
}If latter is true, then binmode is a NOP, so the whole discussion
}would be void.
Binmode on nearly all Unix systems (including OS X) _IS_ a no-op.
--
Matthew T. Russotto russotto@pond.com
"Extremism in defense of liberty is no vice, and moderation in pursuit
of justice is no virtue."
------------------------------
Date: 5 Jan 2001 19:54:08 GMT
From: ilya@math.ohio-state.edu (Ilya Zakharevich)
Subject: Re: Segmented Mac OS X dev tools
Message-Id: <9358p0$r29$1@charm.magnus.acs.ohio-state.edu>
[A complimentary Cc of this posting was sent to Abigail
<abigail@foad.org>],
who wrote in article <slrn95bc4d.nsr.abigail@tsathoggua.rlyeh.net>:
> ~~ > >> cat shouldn't care.
> ~~ >
> ~~ > >Of course it would. Remember C-z?
> ~~ >
> ~~ > "cat" is a Unix program
> ~~
> ~~ ??? What makes a program a "Unix program"?
> History.
Given that this thread is not about history, this makes the above [> ~~ >]
statement off-topic.
Ilya
------------------------------
Date: 05 Jan 2001 21:58:55 GMT
From: seebs@plethora.net (Peter Seebach)
Subject: Re: Segmented Mac OS X dev tools
Message-Id: <3a56439e$0$12798$3c090ad1@news.plethora.net>
In article <933jhs$8e2$1@charm.magnus.acs.ohio-state.edu>,
Ilya Zakharevich <ilya@math.ohio-state.edu> wrote:
>??? What makes a program a "Unix program"?
Being a standard feature of Unix-like systems.
>If latter is true, then binmode is a NOP, so the whole discussion
>would be void.
Probably, and my guess is that the original file was actually corrupt before
he started. Well, truncated anyway; "corrupt" would have gotten a CRC error
in all probability.
-s
--
Copyright 2001, All rights reserved. Peter Seebach / seebs@plethora.net
C/Unix wizard, Pro-commerce radical, Spam fighter. Boycott Spamazon!
Consulting & Computers: http://www.plethora.net/
------------------------------
Date: Fri, 5 Jan 2001 14:49:36 -0600
From: Bin - Lu <b0l4549@cs.tamu.edu>
To: Anno Siegel <anno4000@lublin.zrz.tu-berlin.de>
Subject: Re: socket in perl, help!!
Message-Id: <Pine.SOL.4.10.10101051447490.24681-100000@robert>
Thanks a million, Anno! Your answer is very illuminating.
--Bin
------------------------------
Date: Thu, 4 Jan 2001 16:53:22 GMT
From: adelton@fi.muni.cz (Honza Pazdziora)
Subject: Re: Sorting a Text file Database with perl
Message-Id: <G6nDKy.1F@news.muni.cz>
On Thu, 04 Jan 2001 15:07:45 GMT, jamesdandy@my-deja.com <jamesdandy@my-deja.com> wrote:
> I have a text file DB with five fields. I need to extract three of the
> fields sort by two of them and output the results.
>
> "10|10|madmax|mmax@tdome.com|7"
>
> So far I have tried reading the data into the an array which I then
> split into variables bubble sort these on the appropriate field and
> write the results to a new text file.
>
> This seems much too complicated. Any suggestions?
Instead of your bubble use Perl builtin sort -- perldoc -f sort.
> Also I am currently getting a "name without value" syntax error. The
> syntax is correct, it is the same syntax that works thirty lines up in
> the program. Any advice?
Show us the code (a snippet of it).
Yours,
--
------------------------------------------------------------------------
Honza Pazdziora | adelton@fi.muni.cz | http://www.fi.muni.cz/~adelton/
.project: Perl, DBI, Oracle, MySQL, auth. WWW servers, MTB, Spain.
Petition for a Software Patent Free Europe http://petition.eurolinux.org
------------------------------------------------------------------------
------------------------------
Date: Thu, 4 Jan 2001 16:55:12 GMT
From: adelton@fi.muni.cz (Honza Pazdziora)
Subject: Re: Troubleshooting flock failure
Message-Id: <G6nDo0.1nM@news.muni.cz>
On 4 Jan 2001 10:51:00 -0500, kj0 <kj0@mailcity.com> wrote:
>
> I'm having problems with a hanging flock call requesting an exclusive
> lock on a certain file. I can't see any obvious reason for this lock
> request to hang, since to my knowledge, there's no other process
> locking the file. How can I find out what is causing this flock call
> to hang?
Short of running lsof to see who else has the file open ... probably
not. Isn't the file NFS mounted and your network setup isn't quite
right for locking?
Yours,
--
------------------------------------------------------------------------
Honza Pazdziora | adelton@fi.muni.cz | http://www.fi.muni.cz/~adelton/
.project: Perl, DBI, Oracle, MySQL, auth. WWW servers, MTB, Spain.
Petition for a Software Patent Free Europe http://petition.eurolinux.org
------------------------------------------------------------------------
------------------------------
Date: 05 Jan 2001 16:30:52 -0500
From: Vivek Khera <khera@kciLink.com>
Subject: Re: Uninstalling CPAN modules
Message-Id: <x77l49elf7.fsf@yertle.kciLink.com>
>>>>> "CC" == Chris Cameron <chris@saddlebags.upnix.com> writes:
CC> Is it possible to uninstall CPAN modules? I've looked through all the
CC> FAQ's I could find, but most of them just cover installing the modules.
In the source of your module, (after running perl Makefile.PL) type
"make uninstall" and see what happens.
--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Vivek Khera, Ph.D. Khera Communications, Inc.
Internet: khera@kciLink.com Rockville, MD +1-240-453-8497
AIM: vivekkhera Y!: vivek_khera http://www.khera.org/~vivek/
------------------------------
Date: Fri, 05 Jan 2001 20:29:06 GMT
From: menditto@my-deja.com
Subject: Using variable with metacharacters in regex
Message-Id: <935aq6$5f9$1@nnrp1.deja.com>
Can you include metacharacters in a variable, used in a regex? For
example:
my $s = "abcdef";
my @re = ( "^ab*", "^\s$", ... );
foreach my $i ( @re ) {
if( $s =~ /$i/i ) { print "s=\'$s\' matches pattern \'$i\'\n" }
else { }
}
I get the following error:
"/*/: ?+*{} follows nothing in regexp at foo.pl line N, <IN> line L"
when I attempt to match against lines from file <IN> instead of $s, as
shown above.
PerlFAQ 6.8 "How can I quote a variable to use in a regex?" doesn't
really help me.
If I use index() instead of a regex then I can't use the
metacharacters, which I want. Please help!
Sent via Deja.com
http://www.deja.com/
------------------------------
Date: Fri, 05 Jan 2001 21:48:33 -0000
From: gbacon@HiWAAY.net (Greg Bacon)
Subject: Re: Using variable with metacharacters in regex
Message-Id: <t5cg9hjueeqs59@corp.supernews.com>
In article <935aq6$5f9$1@nnrp1.deja.com>,
<menditto@my-deja.com> wrote:
: Can you include metacharacters in a variable, used in a regex? For
: example:
:
: my $s = "abcdef";
: my @re = ( "^ab*", "^\s$", ... );
: foreach my $i ( @re ) {
: if( $s =~ /$i/i ) { print "s=\'$s\' matches pattern \'$i\'\n" }
: else { }
: }
:
: I get the following error:
: "/*/: ?+*{} follows nothing in regexp at foo.pl line N, <IN> line L"
: when I attempt to match against lines from file <IN> instead of $s, as
: shown above.
The best anyone can do with the information you've provided is to
take a shot in the dark. Paraphrasing code and error messages risks
hiding the problem for no return.
Provide a small but complete example (i.e., something that we can run
on our respective machines) that demonstrates your problem.
Greg
--
I see you've cross-posted this to comp.lang.c and comp.lang.c++. The first
thing you need to do is decide which language you are programming in.
-- Lawrence Kirby
------------------------------
Date: 5 Jan 2001 19:24:08 GMT
From: bmetcalf@nortelnetworks.com (Brandon Metcalf)
Subject: Re: V V easy Question I hope!
Message-Id: <93570o$l2p$1@bcarh8ab.ca.nortel.com>
19wlr@globalnet.co.uk writes:
> If you divide 13 by 4 you get 3 remainder 1
>
> in perl 13 / 4 gives 3.XXXXX
>
> 13 % 4 gives something else
>
> How do you get just the 3 part?
>
> Div and Mod ?
perldoc -f int
Brandon
------------------------------
Date: Fri, 5 Jan 2001 17:05:44 -0500
From: "Andre Lacroix" <lacroix_andre@emc.com>
Subject: Version of AS/400 perl.
Message-Id: <935gft$kbj5@emcnews1.lss.emc.com>
Can anyone tell me what AS/400 version the perl savf was created under from
CPAN sites?
Thanks.
------------------------------
Date: 16 Sep 99 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 16 Sep 99)
Message-Id: <null>
Administrivia:
The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc. For subscription or unsubscription requests, send
the single line:
subscribe perl-users
or:
unsubscribe perl-users
to almanac@ruby.oce.orst.edu.
| NOTE: The mail to news gateway, and thus the ability to submit articles
| through this service to the newsgroup, has been removed. I do not have
| time to individually vet each article to make sure that someone isn't
| abusing the service, and I no longer have any desire to waste my time
| dealing with the campus admins when some fool complains to them about an
| article that has come through the gateway instead of complaining
| to the source.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.
For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V10 Issue 3
************************************