NetBeans Forums

 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
  

Main Class not found after building project

 
Post new topic   Reply to topic    NetBeans Forums -> Java EE Users
View previous topic :: View next topic  
Author Message
TheWolf



Joined: 29 Jun 2011
Posts: 1

PostPosted: Wed Jun 29, 2011 8:36 am    Post subject: Main Class not found after building project Reply with quote

Hello,

I'm quite new to this Forum and didn't find anything in the search, so please just give me a link if I've overseen something.
I just started my first Java projects and everything works well; I can run the project without any problems inside Netbeans. But as soon as I build the project and try to execute the .jar file in \dist\ directory, the cmd opens (for about a millisecond Wink and gives me an java.lang.NoClassDefFoundError ("Could not find the main class").

Do you have any ideas why this is happening? There are two libraries included, I've added both to the classpath (in <projectname>->Properties) and both do exist in \dist\lib directory.

Thanks in advance for your help

TheWolf
Back to top
jyeary



Joined: 21 Oct 2008
Posts: 605
Location: Simpsonville, SC

PostPosted: Fri Jul 01, 2011 2:23 am    Post subject: Re: Main Class not found after building project Reply with quote

This is the wrong forum for GUI based questions, please use the
Back to top
Display posts from previous:   
Post new topic   Reply to topic    NetBeans Forums -> Java EE Users All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB
By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo