Start java web start app from command line
When I need to start a Java webstart app, I usually do it from command line, instead of using a browser. There are 2 slightly different ways to do that:
1. Run javaws
with the url to the jnlp file:
%JAVA_HOME%\bin\javaws http://www.foo123.com/bar/buz.jnlp2. Save the jnlp file locally and run
javaws
command with the local copy. If you enter this jnlp url in the browser's address bar, it will run the app instead of downloading the file. So here I use wget
to download the file.cd %HOMEPATH%\DesktopOption 2 is a bit faster since it doesn't retrieve the jnlp file every time, and can still work even in case of network problem. But the downside is you may not get the latest version of the application. This auto-update is supposed to be the main benefit of jnlp. If your applications don't update frequently, or you don't care running an obsolete version, option 2 is fine.
del buz.jnlp
wget http://www.foo123.com/bar/buz.jnlp
%JAVA_HOME%\bin\javaws %HOMEPATH%\Desktop\buz.jnlp
To make the command shorter, I created a batch file
buz.bat
:@echo off
%JAVA_HOME%\bin\javaws %HOMEPATH%\Desktop\buz.jnlp
rem %JAVA_HOME%\bin\javaws http://www.foo123.com/bar/buz.jnlp
5 comments:
Thanks. That helped! :)
This information is really good and I want to learn more about java WebStart and I think this is the beggining
Great and Useful Article.
Online Java Training
Java Online Training India
Java Online Course
Java EE course
Java EE training
Best Recommended books for Spring framework
Java Interview Questions
Java Course in Chennai
Java Online Training India
Thanks for sharing this good blog.This is very important and imformative blog for Java . very interesting and useful for students
Java Online Training Hyderabad
Web services are client and server applications that communicate over the World Wide Web’s (WWW) HyperText Transfer Protocol (HTTP). Web services provide a standard means of inter operating between software applications running on a variety of platforms and frameworks. Web Design Services
Post a Comment