On 6/6/06, Lakshmi Sailaja <[EMAIL PROTECTED]> wrote:
I wanted to include the shell script, abc, as I want to access a variable.
The shell script, abc, actually takes a value (val) from the user.
I want to use that value (val) in my perl porgram. Is that possible?

Perl may take a value from the user as well, and probably with more
sophistication than a shell script.

ie., I will now call abc in my perl program using system
"/home/xxx/yyy/abc";
The script, abc, asks for a value, val, from the user. After its execution,
I want to use val in my perl program.

Can you suggest the procedure to use val in my Perl program?

But if you insist, one of the more simple ways would be to make the
shell script echo the value just entered by the user, which would be
caught by Perl in a backquote construction:

    `/home/xxx/yyy/abc`

which replaces the call to system.

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to