Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Developer Center > java code running error on xcode

java code running error on xcode
Thread Tools
seen_xu
Junior Member
Join Date: Aug 2003
Status: Offline
Reply With Quote
Jun 23, 2006, 07:12 PM
 
I am totally new to xcode, currently I have version 2.3 installed on my system with Java 5.0 release1, I got a code running under eclipse 3.1.2 without any problem. when I build and run the very same code under xcode, it hints me that it built sucessfully, but after running a error occured.

"Exception in thread "main" java.lang.NoSuchMethodError: main"

I've searched on google, but still can not figure out what i had done wrong.

PS. i tried to create several different java projects to test the same code under xcode, but it seems no different when it runs...

Thx!
Have a Mac, Never Come Back!?
     
Kristoff
Mac Elite
Join Date: Sep 2000
Location: in front of the keyboard
Status: Offline
Reply With Quote
Jun 24, 2006, 12:02 PM
 
um, do you have a method called 'main' that takes one argument of type String[]
signatures are a waste of bandwidth
especially ones with political tripe in them.
     
Ghoser777
Professional Poster
Join Date: Dec 2000
Location: Chicago, Illinois
Status: Offline
Reply With Quote
Jun 29, 2006, 09:40 PM
 
The Manifest file also has to specify which of the Class files has the main method that you want to execute (assuming you're doing a Java Tool). What Project type are you selecting in Xcode?
     
   
 
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Top
Privacy Policy
All times are GMT -4. The time now is 03:25 AM.
All contents of these forums © 1995-2017 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.8 © 2000-2017, Jelsoft Enterprises Ltd.,