I
I
Ivan02062015-09-28 10:43:22
Java
Ivan0206, 2015-09-28 10:43:22

Running java program from console?

Hello!
Description: I wrote a simple java program, compiled it into a jar file, now I want to run it in the console on windows to work in the program I wrote.
How can I implement this? Tell me what commands to use to open a file in the console, or in which direction to read?
Thank you! All the best!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
R
Riard Brugekaaim, 2015-09-28
@OLDRihard

It is necessary to launch not only and not so much jar as the java machine itself and specify the required jar as a parameter.
As I understand it, the launch will be from an application in another language, for example, for C ++, Google gives this: execl("java","java","jar myprog.jar",NULL);

A
Alexey Ukolov, 2015-09-28
@alexey-m-ukolov

stackoverflow.com/questions/1238145/how-to-run-aj...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question