exec command stops thread

J

Junkone

hello
i am trying to do the following
exec("copy e:\\data\\stocks\\watchlists\\*.* E:\\data\\MergedDb\
\watchlists\\*.*")
puts "copied"

My prog execution stops after exec is done. not sure why. how can i
run a command and continue processing after the command.
 
B

botp

exec("copy e:\\data\\stocks\\watchlists\\*.* E:\\data\\MergedDb\
\watchlists\\*.*")
puts "copied"

My prog execution stops after exec is done. not sure why. how can i
run a command and continue processing after the command.

when #exec executes, it will replace the (whole) current running
program/process; thus you wont reach the "puts copied" portion..

try system or the backticks "`"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top