|
From: Daniel M. <dan...@be...> - 2006-02-08 15:20:21
|
I have a C#/.NET 2.0 GUI application I use as a front end to a Java application I have developed. Traditionally, this Java app was invoked via a DOS batch script which constructed classpaths and executed the Java command directly. Within the GUI application, I was able to invoke the batch script and redirect stdout and stderr to capture the Java app's output in realtime and display it to the user. In order to gain more control over the indirectly-invoked Java app, I have encapsulated it in the Service Wrapper, to good effect (For instance, I can now capture the pid of the Java/wrapper instance and kill it from the C# application). I realize this isn't necessarily the intent of the wrapper, but launch4j can't do all the classpath stuff I need, and I don't have access to an exe4j license. So bear with me... My problem is this: since I modified the batch script to invoke the wrapper rather than the Java command itself to launch the application, my C# application no longer gets realtime output from stdout/stderr when the wrapper is running. The C# code itself hasn't changed; in fact, output from the batch script itself gets redirected properly and in realtime as before. It's just the wrapper output which is funky: it doesn't actually get passed back to stdout until it's completely run its course.=20 Any ideas what could be causing this? Obviously it's redirecting somewhat properly, because I do eventually get the stdout stream... but not until the end of the wrapper execution. I searched and couldn't find any configuration properties related to output redirection. Heeeelllp! :) Daniel Mace Software Engineer, Payroll Integration benefitfocus.com 843-849-7476 x393 *************************************************************************= *************** BENEFITFOCUS.COM CONFIDENTIALITY NOTICE: This electronic message is = intended only for the individual or entity to which it is addressed and = may contain information that is confidential and protected by law. = Unauthorized review, use, disclosure, or dissemination of this = communication or its contents in any way is prohibited and may be = unlawful. If you are not the intended recipient or a person responsible = for delivering this message to an intended recipient, please notify the = original sender immediately by e-mail or telephone, return the original = message to the original sender or to bfp...@be..., and = destroy all copies or derivations of the original message. Thank you. = (BFeComNote Rev. 08/01/2005) *************************************************************************= ************** |