?
Solved

shortcut to  execute java program

Posted on 2005-05-04
2
Medium Priority
?
133 Views
Last Modified: 2011-09-20
Hi,
I would have a java program that is to be run by some non technical users. I want to create a short cut to that program on the desktop so that when the user clicks on it the program is executed. I also want the output/errors to be redirected to a directory.

the java program is in c:\javaproject\HelloWorld.java
the log is in c:\temp\java.log.
Thanks,
Anu
0
Comment
Question by:anumit
  • 2
2 Comments
 
LVL 8

Expert Comment

by:anil_u
ID: 13930654
Why not create a batch file
Open notepad
Type (without quotes)
"java HelloWorld >> c:\temp\java.log"

then save it as HelloWorld.bat

Now doublicking on it should save the output to the temp folder

Note: java Helloword is how I am assuming you run the program using the command line, if not then just replace it with what you use.
Hope I could help
0
 
LVL 8

Accepted Solution

by:
anil_u earned 500 total points
ID: 13930665
"java c:\javaproject\HelloWorld >> c:\temp\java.log"

Actually you need the full path if you want to run it from your desktop
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

NTFS file system has been developed by Microsoft that is widely used by Windows NT operating system and its advanced versions. It is the mostly used over FAT file system as it provides superior features like reliability, security, storage, efficienc…
Social messanging services like WhatsApp and Facebook can help businesses in ways that many owners don't even imagine, giving new opportunities to connect with customers. Discover some of the most innovative things they can do for your company.
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…
When cloud platforms entered the scene, users and companies jumped on board to take advantage of the many benefits, like the ability to work and connect with company information from various locations. What many didn't foresee was the increased risk…
Suggested Courses
Course of the Month16 days, 17 hours left to enroll

864 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question