Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: assigning system command output to a variable

by Rex(Wrecks) (Curate)
on Sep 02, 2003 at 21:50 UTC ( #288451=note: print w/ replies, xml ) Need Help??


in reply to assigning system command output to a variable

From putting "system" into the search bar at the top of the page:

"The return value is the exit status of the program as returned by the wait() call. To get the actual exit value divide by 256. See also exec. This is NOT what you want to use to capture the output from a command, for that you should use merely backticks or qx//, as described in `STRING`."

From looking up "backticks" I got a whole list of nodes that should put you on the right path.

The reason I explained this is to show how easy it is to get information on this site if you just try :)

"Nothing is sure but death and taxes" I say combine the two and its death to all taxes!


Comment on Re: assigning system command output to a variable

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (15)
As of 2014-08-29 16:36 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (282 votes), past polls