Suggestion 1 :- There is a function available in
C++ that allows you to spawn processes.
Have a look at that function to launch .exes'.
I am sorry I cannot I remember the name of the function
but if you search for spawning processes in your IDE
you may be able to find it.
I have tried it and it works fine.
You can observe the processes being spawned in the task manager
if you have NT although not in Java.
The advantage of Spawning processes is that your JSP will
continue to execute while the Printer excutes in a separate
thread.
Suggestion 2 :- To Run the printer perhaps you should consider
calling the Printer Driver directly which normally comes in the form
of a C/C++ DLL.
Perhaps you should also consider combining
java.lang.Runtime.exe() with the Thread class
hence taking advantage of processes running
in separate threads there by again releasing your JSP
to continue its path of execution of code unless you want to wait
for the printer to execute. However as you do not really have
any control over success or failure perhaps you should consider threads.
Regards,
Zahid R.
----- Original Message -----
From: "Jacek Antoniuk" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, August 24, 2001 12:16 AM
Subject: Re: Launching an exe from either a JSP or within Java
> You can use JNI interface - but you would have to recompile your external
> application or write in C/C++ an app that calls your exe.
> ----- Original Message -----
> From: "Haseltine, Celeste" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Thursday, August 23, 2001 7:12 PM
> Subject: Launching an exe from either a JSP or within Java
>
>
> > Does anyone know how you can launch another exe resident on the host
> server
> > from within a JSP or in a Java class bean? I have found a third party
> tool
> > that can send data to industrial printers from a DOS command line,
> inclusive
> > of command line parameters. But for the life of me I cannot remember
how
> to
> > "emulate" launching an executable from the command line in either Java
or
> > JSP.
> >
> > Thanks in advance!!!
> >
> > Celeste
> >
> >
>
===========================================================================
> > To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> JSP-INTEREST".
> > For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
> DIGEST".
> > Some relevant FAQs on JSP/Servlets can be found at:
> >
> > http://java.sun.com/products/jsp/faq.html
> > http://www.esperanto.org.nz/jsp/jspfaq.html
> > http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
> > http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets
>
>
===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
> For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
> http://java.sun.com/products/jsp/faq.html
> http://www.esperanto.org.nz/jsp/jspfaq.html
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets
>
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets