m unable to run executable jar.I created one on swing based prgm using command:
jar cmf my.mf demo.jar *.*
.....problem is this that it does not show everything added on Jframe..it just shows a frame and no buttons,textfields,etc which i have added...

waiting for a good response..!!

Open your jar file with any zip program (a jar is just a .zip) and see if all your other classes and other resources are present and in the right folders etc. Make sure you are catching all exceptions and sending them to System.out (or, better, System.err).

yes - also, make sure you (depending on your IDE if you are using one) do a clean / build of your code to ensure that there are not any old files from a previous build being packed into the JAR.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.