Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re^3: How can I control interactive cli executables on Windows from Perl

by FitTrend (Pilgrim)
on Mar 30, 2005 at 15:54 UTC ( #443525=note: print w/ replies, xml ) Need Help??


in reply to Re^2: How can I control interactive cli executables on Windows from Perl
in thread How can I control interactive cli executables on Windows from Perl

I understand. Since that is the case, here is what I recommend.

You can use two additional methods not already talked about above. first one is the system command which will allow you to execute commands to the exe and wait for completion.

system ("$ENV{'WINDIR'}\\system32\\telnet 10.1.1.10"); # OR ANY EXE AN +D PARAMETERS

Otherwise, you can use the backtick to take the output of a command and place it into a variable.

$test = `dir c:\\`; print scalar $test;

You can dump the output of system into a variable as well. Hope this helps


Comment on Re^3: How can I control interactive cli executables on Windows from Perl
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://443525]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (5)
As of 2014-12-21 20:57 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (108 votes), past polls