Start Command Prompt.
Navigate to the folder that holds your class files:
--C:\>cd \mywork
Set path to include JDK’s bin. For example:
--C:\mywork> path c:\Program Files\Java\jdk1.5.0_09\bin;%path%
Compile your class(es):
---C:\mywork> javac *.java
Create a manifest file:
---C:\mywork> echo Main-Class: DanceStudio >manifest.txt
Create a jar file:
---C:\mywork> jar cvfm DanceStudio.jar manifest.txt *.class
Test your jar:
---C:\mywork> DanceStudio.jar
Jar Link