michbach has asked for the wisdom of the Perl Monks concerning the following question:
best regards, michbachuse Tk; #================================================ # Main-Window #================================================ $HF = new MainWindow (-title => "Main-Window"); $HF->geometry('100x100'); #================================================== # Buttons #================================================== $BtnStart = $HF->Button ( -text=>"START", -command => \&ext, -borderwidth => 2, -relief => raised, )->pack(); $BtnStop = $HF->Button ( -text=>"STOP ", -command => sub{close (FH);$HF->update();}, )->pack(); #================================================ # Tk-End #================================================ MainLoop(); #================================================ # SUB-Programs #================================================ sub ext { #xxxx Pipe to the external programm open(FH, "c:\\extern.exe |"); while($tp=<FH>) { print "\n$tp"; $HF->update(); } }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: stop pipe
by zentara (Cardinal) on Mar 29, 2009 at 16:43 UTC | |
by michbach (Sexton) on Mar 29, 2009 at 19:27 UTC | |
Re: stop pipe
by samtregar (Abbot) on Mar 29, 2009 at 18:22 UTC | |
by michbach (Sexton) on Mar 29, 2009 at 19:35 UTC | |
by zentara (Cardinal) on Mar 30, 2009 at 11:12 UTC |