Got problem with jar-file, any help?
I've been learning java through my study for the past few months, so I'm not new to it anymore, still I don't know if this is considered to be advanced. Anyway, let's have a go:
I am trying to make a jar-file for the first time, so that Windows-users may run the file without using Textpad
So far, I've tried followed the necessary(?) hints in the internet, and it's still not working.
The file is called maria.class
This is the manifest.txt:
And yes, I'm aware of following rule:
"Warning: The text file must end with a new line or carriage return. The last line will not be parsed properly if it does not end with a new line or carriage return."
So I've typed in an open line below the text.
Then I've have typed the following commands in command prompt:
echo Main-Class: maria >manifest.txt
jar cvfm maria.jar manifest.txt maria.class
When I try to open the maria.jar file, I get this message in return:
Could not find the main class: maria. Program will exit
Any ideas of how to solve this?
And yes, I got java SDK installed, and I've set the path to SDK's bin folder.
And yes, I got a main-method in the class file.
Any help would be great.