So, I was trying to run a Jar I compiled and this "Failed to load Main-Class manifest attribute from
text.jar" Came up. I looked up the issue and tried to fix the Manifest, however whatever I try fails. Can anyone help me with this?
Printable View
So, I was trying to run a Jar I compiled and this "Failed to load Main-Class manifest attribute from
text.jar" Came up. I looked up the issue and tried to fix the Manifest, however whatever I try fails. Can anyone help me with this?
Where did you look? If you haven't done so read Setting An Application's Entry Point and surrounding sections of Oracle's Tutorial. Take special note of the 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" which is a common gotcha.
If you continue to have problems it would make things clearer if you posted the actual manifest file you are using, the command you use to create the jar file and the source (.java) file of the class containing the entry point.
Ok. I was using Eclipse to do this and it turns out I didn't actually select runnable Jar file, just ordinary jar file. That was why it wasn't working. Thanks for the help though!