469,649 Members | 1,407 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,649 developers. It's quick & easy.

How to execute external file?

Tom
Hi,

I wrote a java console program. But, I am not familiar with Swing to write
the GUI.

I want to use C# to write the GUI, e.g. a start and a stop buttons.

When I click the start button, it execute the jar file. Or, I wrote a batch
file and let the GUI to run it.

So, how should I write the eventhandler to execute the external program?

Thanks for help.


Nov 16 '05 #1
4 5301
Tom wrote:
Hi,

I wrote a java console program. But, I am not familiar with Swing to
write the GUI.

I want to use C# to write the GUI, e.g. a start and a stop buttons.

When I click the start button, it execute the jar file. Or, I wrote a
batch file and let the GUI to run it.

So, how should I write the eventhandler to execute the external
program?


The class System.Diagnostics.Process allows you to run other programs.

If you're only using JDK 1.1 APIs in your Java application, you could
recompile it using J# to a .NET assembly and use it as regular DLL...

Cheers,
--
Joerg Jooss
jo*********@gmx.net
Nov 16 '05 #2
Tom
> The class System.Diagnostics.Process allows you to run other programs.

If you're only using JDK 1.1 APIs in your Java application, you could
recompile it using J# to a .NET assembly and use it as regular DLL...


I use JDK 1.4.1 in my java program.

May I ask how can I run the jar program as a service on windows 2000 server?
Nov 16 '05 #3
Tom wrote:
The class System.Diagnostics.Process allows you to run other
programs.

If you're only using JDK 1.1 APIs in your Java application, you could
recompile it using J# to a .NET assembly and use it as regular DLL...


I use JDK 1.4.1 in my java program.

May I ask how can I run the jar program as a service on windows 2000
server?


I haven't looked into service development in detail, but the .NET framework
has good support for developing services. On the other hand, there are
(freely avalibale) tools that let you execute any Win32 application as a
service.

Cheers,
--
Joerg Jooss
jo*********@gmx.net
Nov 16 '05 #4
Tom
FYI: http://www.geocities.com/j2exe/ is a good tool.
Nov 16 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Juan Manuel Alegrķa B. | last post: by
14 posts views Thread by technocrat | last post: by
4 posts views Thread by Michele Petrazzo | last post: by
19 posts views Thread by citronelu | last post: by
4 posts views Thread by =?Utf-8?B?TEJU?= | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.