• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

RUN JAVA APPLICATION WITHOUT JRE

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
HI,
I HAVE MADE ONE PROJECT IN JAVA AND I HAVE TO RUN IT ON A MACHINE IN WHICH THERE IS NO JAVA RUNTIME ENVIRONMENT. HOW COULD I INSTALL / RUN IT ON THAT MACHINE ??? CAN A JAVA APPLICATION BE DISTRIBUTED ON THAT MACHINE ???
PLZ HELP ME....
REGARDS,
RONAK PATEL
roneypatel@indiatimes.com
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi
I think you are trying to use in a way which is not possibe.........
Just for information if you try to run any Java application you have to be forst install the JVM first and then the application else try to make web based application using JSP and Servlet.
Thanks
Amitesh
 
Ranch Hand
Posts: 5093
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
you can distribute the application without a JVM but then the customer won't be able to use it without first obtaining and installing a JVM themselves.
 
Ranch Hand
Posts: 113
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello Roney,
As far as i get it you have designed a java based application and want to run it on a client machine no matter whether a jre/jdk is installed or not. If this is the scenario in which you want to simply run the application without the client having to go through the hassles of installing the jvm then i think embedding the jre in your application is a suitable way out.
To embed a jre you have copy the jre folder in your machine into your local path and point the java home, class path, system path etc. to that directory so that the os can find the javaw.exe without any sort of trouble.
So, the installatio directory should look like:
<install>
|--- <jre>
| |--- bin
| |--- ...
|--- Your files...
in the startup script you can place commands like this.
set path=%path%;./jre/bin;
set classpath=%classpath%;.;./jre/lib/tools.jar;
.....
.....
javaw <your application>
Another approach is to use java based installers like exe4j etc. which make exe for java applications and enable you to run your code directly.
I hope it helps.
 
I don't always make ads but when I do they're tiny
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic