M
MTiN
Gast
tja, ich hab jetzt mehr oder weniger mein erstes kleines Java-Projekt fertig. Bis jetzt hab ich immer in Netbeans einfach nur Shift+F6 (Text Programm) gedrückt, wodurch das ganze compiliert oder wasweißdennich auf jeden Fall wurde es gestartet 
jetzt möchte ich das natürlich aber auch so, ohne Netbeans starten können...dazu bin ich auf Build Project gegangen und dann in meinem Projektordner in den Ordner dist wo mein Projekt.jar war. Daneben is ne Readme-Datei in der steht
also bin ich mit der Kommandozeile in den Ordner un hab das eingegeben, allerdings passierte da nichts. Keine Fehlermeldung, aber auch kein Programm. hab dann die Zeile auch in ne .bat Datei gemacht, gleicher Effekt...als wenn ich gar nichts eingeben würde und nur Enter drücken würde....
hat da jemand ne Ahnung was ich falsch machen könnte?
jetzt möchte ich das natürlich aber auch so, ohne Netbeans starten können...dazu bin ich auf Build Project gegangen und dann in meinem Projektordner in den Ordner dist wo mein Projekt.jar war. Daneben is ne Readme-Datei in der steht
Code:
========================
BUILD OUTPUT DESCRIPTION
========================
When you build an Java application project that has a main class, the IDE
automatically copies all of the JAR
files on the projects classpath to your projects dist/lib folder. The IDE
also adds each of the JAR files to the Class-Path element in the application
JAR files manifest file (MANIFEST.MF).
To run the project from the command line, go to the dist folder and
type the following:
java -jar "Projekt.jar"
To distribute this project, zip up the dist folder (including the lib folder)
and distribute the ZIP file.
Notes:
* If two JAR files on the project classpath have the same name, only the first
JAR file is copied to the lib folder.
* If the classpath contains a folder of classes or resources, none of the
classpath elements are copied to the dist folder.
* If a library on the projects classpath also has a Class-Path element
specified in the manifest,the content of the Class-Path element has to be on
the projects runtime path.
* To set a main class in a standard Java project, right-click the project node
in the Projects window and choose Properties. Then click Run and enter the
class name in the Main Class field. Alternatively, you can manually type the
class name in the manifest Main-Class element.
also bin ich mit der Kommandozeile in den Ordner un hab das eingegeben, allerdings passierte da nichts. Keine Fehlermeldung, aber auch kein Programm. hab dann die Zeile auch in ne .bat Datei gemacht, gleicher Effekt...als wenn ich gar nichts eingeben würde und nur Enter drücken würde....
hat da jemand ne Ahnung was ich falsch machen könnte?