This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Java in General and the fly likes Error in Eclipse and Netbeans Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Java » Java in General
Bookmark "Error in Eclipse and Netbeans" Watch "Error in Eclipse and Netbeans" New topic

Error in Eclipse and Netbeans

Serap Elbeyoglu
Ranch Hand

Joined: Feb 12, 2010
Posts: 52
Hello to everyone,

I write Java codes, but I face syntax & runtime errors both in Eclipse and NetBeans.

The source codes are from I copy-paste, but see the errors. I am careful class name.

Eclipse Message = Prints the ASM code to generate the given class.
Usage: ASMifierClassVisitor [-debug] <fully qualified class name or class file name>

NetBeans Message = no Main class found

How can I solve my problem?

Thank you

Serap Elbeyoglu
Wouter Oet
Saloon Keeper

Joined: Oct 25, 2008
Posts: 2700

I don't know what the eclipse error means but the netbeans error is simple. There is no main method thus no entry point in the program. Maybe if you showed some code we could help you further.

"Any fool can write code that a computer can understand. Good programmers write code that humans can understand." --- Martin Fowler
Please correct my English.
Serap Elbeyoglu
Ranch Hand

Joined: Feb 12, 2010
Posts: 52
Hi Wouter,

I don't like to copy-paste the whole source code here. But I am trying to find an answer. Guess that, you wrote a source code with Eclipse, code was from Sun's page. It had no syntax error. you made the essential changes about class name. You run your code. Eclipse said:

"Serap_Text_Demo.Main class wasn't found in Serap'sProject." What would you do?

Lorand Komaromi
Ranch Hand

Joined: Oct 08, 2009
Posts: 276
Serap Elbeyoglu wrote:"Serap_Text_Demo.Main class wasn't found in Serap'sProject." What would you do?

I'd check if the class exists in the project.

OCJP 6 (93%)
Darryl Burke

Joined: May 03, 2008
Posts: 4992

I'd also avoid punctuation characters other than the underscore in file ad folder names. Don't know whether it's the case here, but a name like "Serap'sProject" sure looks like a possible source of grief.

luck, db
There are no new questions, but there may be new answers.
Serap Elbeyoglu
Ranch Hand

Joined: Feb 12, 2010
Posts: 52
hey friends, thank you for your replies. they were helpful. but I couldn't solve the trouble.

any ideas?
Roberto Perillo

Joined: Dec 28, 2007
Posts: 2270

Howdy, Serap!

Is there a stack trace? If so, please paste it here so we can try to help you in a more concise way.

Cheers, Bob "John Lennon" Perillo
SCJP, SCWCD, SCJD, SCBCD - Daileon: A Tool for Enabling Domain Annotations
Serap Elbeyoglu
Ranch Hand

Joined: Feb 12, 2010
Posts: 52
Hello Roberto, here is the source code from Sun's page. Actually is has no syntax or another errors. In NetBeans IDE 6.8, firstly I open a new project. Secondly, I think this source code is an application, so I click application button. I make the class name "TextDemo", because of source code's class name. But I want to understand why I cannot run this application.

Thank you all, for your interest.
Have you checked out Aspose?
subject: Error in Eclipse and Netbeans
jQuery in Action, 3rd edition