While going through some online java tutorials (at oracle) I found two ways of running them. 1> Java Web Start, 2> Copy the code onto your computer and compile.
Java Web Start is the latest technology where java code at server will run on your laptop. I was going through 'Swing' (GUI/browser) tutorials and I selected option 1.
Now when the 'jnpl' file is downloaded on your machine, it invokes the required JRE and will try to run the program.
The problem I was facing is, when trying to execute the JNPL file, I was getting error 'unable to launch the application' and in 'details tab' I found that it was unable to find JRE1.7, even while I've got the needed jre installed. To find out your installed jre version, on cmd type 'java -version'. This problem was stopping me from running tutorials using Java Web Start.
Below solution worked for me (windows 7)
1> Control Panel > Java icon
2> General tab > Temporary Internet Files > Settings. This will pop-up a window with 'Delete Files' button. Delete the pre-selected two options.
This should work generally, but my problem still persisted. Then proceed to 3
3> In step 2, copy the Location of temporary files. (for me: C:\Users\IBM_ADMIN\AppData\LocalLow\Sun\Java\Deployment\cache) and go to that folder.
4> Delete whatever is there. For me, there was a folder '6.0', maybe because I've another JRE1.6 running on my machine.
5> Once I deleted this folder, and again tried running the JNPL file it worked flawless for me!
Hope this works for you too!
Java Web Start is the latest technology where java code at server will run on your laptop. I was going through 'Swing' (GUI/browser) tutorials and I selected option 1.
Now when the 'jnpl' file is downloaded on your machine, it invokes the required JRE and will try to run the program.
The problem I was facing is, when trying to execute the JNPL file, I was getting error 'unable to launch the application' and in 'details tab' I found that it was unable to find JRE1.7, even while I've got the needed jre installed. To find out your installed jre version, on cmd type 'java -version'. This problem was stopping me from running tutorials using Java Web Start.
Below solution worked for me (windows 7)
1> Control Panel > Java icon
2> General tab > Temporary Internet Files > Settings. This will pop-up a window with 'Delete Files' button. Delete the pre-selected two options.
This should work generally, but my problem still persisted. Then proceed to 3
3> In step 2, copy the Location of temporary files. (for me: C:\Users\IBM_ADMIN\AppData\LocalLow\Sun\Java\Deployment\cache) and go to that folder.
4> Delete whatever is there. For me, there was a folder '6.0', maybe because I've another JRE1.6 running on my machine.
5> Once I deleted this folder, and again tried running the JNPL file it worked flawless for me!
Hope this works for you too!