 |
|
Home:
Perl Programming Help:
Beginner:
Re: [bishop] my parameters won't pass through a pipe:
Edit Log
|
|

KevinR
Veteran

Jul 30, 2009, 8:31 PM
Views: 1205
|
|
Re: [bishop] my parameters won't pass through a pipe
|
|
|
I have the same problem on Vista but it works for me like this:
use strict; use warnings; my $PARAMETERS = "parameters"; open (OUTPUT,"perl c:/PerlTest/foo.pl $PARAMETERS|") or die "$!"; my $testresult = <OUTPUT>; close (OUTPUT); print $testresult; Code for foo.pl:
#!perl print "@ARGV"; exit; Even though I have .pl set to open with perl (strawberry perl 5.10 on Vista 64 bit) it will not pass the parameters unless I include perl on the open line. Perl is in the command path so just using "perl" works. I can't find how to do what Fish suggests on Vista. -------------------------------------------------
(This post was edited by KevinR on Jul 30, 2009, 8:33 PM)
|
|
|
Edit Log:
|
|
Post edited by KevinR
(Veteran) on Jul 30, 2009, 8:31 PM
|
|
Post edited by KevinR
(Veteran) on Jul 30, 2009, 8:33 PM
|
|
|  |