Dear babarhussain29,
Brief Theory:
As far as I know, every jar file is an archive just like .zip, .gz file etc.
In it there resides a file known as MANIFEST.MF usually in a folder META-INF.
In this file there is an entry as
Main-Class: a.b.programs_main
(where program_main is your main class file, if you know java programming I hope you can understand concept of main class well. a and b etc are top level directory.)
What seems:
So perhaps the aforementioned entry is missing from the MANIFEST.MF file.
This may be due to the file is corrupted (let say in downloading), or if you have manually created it, then it may be you haven't put above line or forgot to create entire menifest file.
Can you tell us where you have got that file?
Possibly, you can manually unpack that jar file and edit MANIFEST.MF for the main class entry and repack and run it again.
|