Results 1 to 11 of 11
Thread: JAR files
- 01-25-2010, 07:43 PM #1
Member
- Join Date
- Sep 2009
- Posts
- 21
- Rep Power
- 0
-
I'm not sure what kind of answer you expect here. Understand that you're not asking a specific question, but rather are asking about a general subject, how "in detail" to create Jar files. This subject when discussed in the tutorials takes several pages to describe. I'm not sure how you expect us to answer this better than the tutorials or your textbook or how are we expected to know just what it is you don't understand, much less how we are going to have the time to write essentially a book chapter seeing as how we are all volunteers with jobs/lives/families...
My suggestion is that you go through the Sun tutorials again but this time taking notes. Then after going through them, review your notes and come on back with any specific questions or misunderstandings that you have.
You may also want to read this link as I know that it has helped me and others here to ask questions that are more easily answered: How To Ask Questions The Smart Way
Best of luck!Last edited by Fubarable; 01-25-2010 at 07:52 PM.
- 01-25-2010, 08:08 PM #3
Member
- Join Date
- Sep 2009
- Posts
- 21
- Rep Power
- 0
I need help with the command.
At the moment I have:
Java Code:jar cvf Chat.jar *
In a command file. This causes the above (jar cvf Chat.jar *) to be echoed repeatedly. I'd like to ask, what am I doing wrong?
- 01-25-2010, 08:11 PM #4
Start with
Lesson: Packaging Programs in JAR Files
and work with the section
Using JAR Files: The Basics
with special attention to the creating, viewing and running sections.
Then work with this page
Working with Manifest Files: The Basics
and especially this
Setting an Application's Entry Point
It takes patience and practice to work through these tutorial pages.
- 01-25-2010, 08:22 PM #5
I just made a folder named "jarTest" and copied a source file "A" and its class files into it.
Navigating to the folder and then executing:
I got a jar file "AJar" appearing inside the folder and the following output:Java Code:jar cvf AJar.jar *
Java Code:C:\jexp\jarTest>jar cvf AJar.jar * added manifest adding: A$1.class(in = 1637) (out= 954)(deflated 41%) adding: A$2.class(in = 678) (out= 446)(deflated 34%) adding: A$3.class(in = 977) (out= 637)(deflated 34%) adding: A.class(in = 7665) (out= 4071)(deflated 46%) adding: A.java(in = 14478) (out= 4217)(deflated 70%)
- 01-25-2010, 09:01 PM #6
Member
- Join Date
- Sep 2009
- Posts
- 21
- Rep Power
- 0
Exactly how did you execute it? I'm a bit lost. :s
- 01-25-2010, 09:13 PM #7
how did you execute it
I typed this at the prompt
and pressed the enter key.Java Code:C:\jexp\jarTest>jar cvf AJar.jar *
This makes a jar file including all files inside the "jarTest" folder.
Note from the path in the prompt that the current directory is the "jarTest" folder.
I navigated to that folder with the "cd" command at the prompt
and pressing enter, resulting inJava Code:C:\jexp>cd jarTest
Java Code:C:\jexp\jarTest>
- 01-25-2010, 09:18 PM #8
Member
- Join Date
- Sep 2009
- Posts
- 21
- Rep Power
- 0
That worked, thanks alot. :)
- 01-25-2010, 10:38 PM #9
Moderator
- Join Date
- Feb 2009
- Location
- New Zealand
- Posts
- 4,546
- Rep Power
- 11
@OP You mentioned that you had the command in a command file of some sort. If you had named that file "jar dot some executable extension" then the OS may have got confused and kept on calling the command file rather than the actual jar executable. That would explain the continual display of the command on the screen.
-
bigj, please ask your new question in a new thread. Thanks.
- 01-26-2010, 01:44 PM #11
Member
- Join Date
- Dec 2009
- Posts
- 68
- Rep Power
- 0
Similar Threads
-
working with files (text files)
By itaipee in forum New To JavaReplies: 1Last Post: 02-24-2009, 11:38 AM -
Behaving text files like binary files
By Farzaneh in forum New To JavaReplies: 2Last Post: 08-27-2008, 03:20 PM -
Text and image files within jar files
By erhart in forum Advanced JavaReplies: 8Last Post: 01-19-2008, 04:43 AM -
how to convert mpeg files to .wav files
By christina in forum New To JavaReplies: 1Last Post: 08-06-2007, 04:14 AM -
convert xls files into pdf files
By bbq in forum New To JavaReplies: 3Last Post: 07-20-2007, 03:56 AM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks