launching windowed program with Runtime#exec() under Tomcat 5.0

2005-03-25 Thread Steve-O
I've been looking through the archives and reading the posts regarding Tomcat and Runtime#exec(). Almost everything I've read about Runtime#exec() points to the javaworld article on the pitfalls of Runtime#exec(). However, most of the examples seem to be for commands or shell scripts where

Re: launching windowed program with Runtime#exec() under Tomcat 5.0

2005-03-25 Thread Jason Bainbridge
How are you running Tomcat? As a service? Try running it via startup.bat so it uses your credentials and then trying. Also try checking Allow service to interact with desktop if you are running the service as Localsystem (although I wouldn't recommend doing that for Production use, I'd create an

Re: launching windowed program with Runtime#exec() under Tomcat 5.0

2005-03-25 Thread Steve-O
Dear Jason, Thank you for the reply. I'm not running Tomcat as a service. Originally, I was running it as a service and I even checked Allow service to interact with desktop. After that failed, I tried running it simply using start.bat. Cheers, Steve On Mar 25, 2005, at 12:56 PM, Jason

Re: launching windowed program with Runtime#exec() under Tomcat 5.0

2005-03-25 Thread Markus Schönhaber
Am Freitag, 25. März 2005 18:51 schrieb Steve Butcher: Then I build that into a class: public class Launcher {      public static main( String[] args) throws Exception {           new Launcher().play();      }      public void play() throws Exception {           String

Re: launching windowed program with Runtime#exec() under Tomcat 5.0

2005-03-25 Thread Jason Bainbridge
On Fri, 25 Mar 2005 13:14:45 -0500, Steve-O Steve Butcher [EMAIL PROTECTED] wrote: Dear Jason, Thank you for the reply. I'm not running Tomcat as a service. Originally, I was running it as a service and I even checked Allow service to interact with desktop. After that failed, I tried

Re: launching windowed program with Runtime#exec() under Tomcat 5.0

2005-03-25 Thread Jason Bainbridge
On Fri, 25 Mar 2005 19:31:48 +0100, Markus Schönhaber [EMAIL PROTECTED] wrote: Am Freitag, 25. März 2005 18:51 schrieb Steve Butcher: Does vlc produce any output on stdout/stderr? If it does, it may stop when the output-buffer fills up. So you have to read Process#getOutputStream() to make it

Re: launching windowed program with Runtime#exec() under Tomcat 5.0

2005-03-25 Thread Steve-O
On Mar 25, 2005, at 1:31 PM, Markus Schönhaber wrote: Am Freitag, 25. März 2005 18:51 schrieb Steve Butcher: Does vlc produce any output on stdout/stderr? If it does, it may stop when the output-buffer fills up. So you have to read Process#getOutputStream() to make it continue. Regards mks I

Re: launching windowed program with Runtime#exec() under Tomcat 5.0

2005-03-25 Thread Steve-O
w00t! I got it to work. It turns out that VLC *is* sending output to both stderr and stdout. From the oft-mentioned JavaWorld article, http://www.javaworld.com/javaworld/jw-12-2000/jw-1229-traps_p.html, I added the StreamGobblers to play(); public void play() throws Exception { String command