Try using backticks and you can bg it like you would any unix process from the command line, I am on WinXP and would probably use Win32::Process... but you can just do something like:
my $rv = `someprog &`; # try this instead of your system() call...
Since I am not on a Unix box that is an untested line
Tk's main loop keeps running until you exit... There is a better way to do non-blocking system calls however... you should do some reading of the perl/tk faq's or read about it in Mastering Perl/Tk which is an O'Reilly book ( ISBN 1-56592-716-8) I believe the Schwartz book you are referring to is "Learning Perl". The Perl/Tk book is all about the Perl/Tk implementation and assumes you already are familiar with Perl.
JamesNC | [reply] |
JamesNC you gave me the idea to try the & inside my system call. I came up with this.
system("$text &");
exit;
I put this im my sub, and it works great. I am going to expand this to hold a history and add error checking for commands inputed to make sure they work and let you know if you get a command not found. Thank you for the idea JamesNC.
Thank you | [reply] [d/l] |