Register FAQ / Rules Forum Spy Search Today's Posts Mark Forums Read
Go Back   MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Reply
 
Thread Tools Search this Thread Display Modes
Old Mar 11, 2012, 03:32 PM   #1
macuser1232
macrumors 6502a
 
Join Date: Jan 2012
Xcode won't let me build and run.

Hey guys so I just started a new project on xcode using command line and then I clicked on C++. When I go to source files and then go to main.cpp it doesn't let me click on the build and run button at the top.
macuser1232 is offline   0 Reply With Quote
Old Mar 12, 2012, 11:52 AM   #2
szymczyk
macrumors regular
 
Join Date: Mar 2006
You need to provide some more information for people to be able to help you. What version of Xcode are you using? Your mention of the Build and Run button tells me you're not using Xcode 4.

When you say the following:

Quote:
using command line and then I clicked on C++
Do you mean you created a C++ command-line tool project?

Are you able to build and run the project from Xcode's menus? Xcode 2 and 3 have a Build menu that has a Build and Run menu item.

If you click the link in my signature, you can find two articles that walk you through the creation of a C++ command-line application project in Xcode. One article covers Xcode 4 and the other covers earlier versions of Xcode.
__________________
Mark Szymczyk
Author, Xcode Tools Sensei
http://www.meandmark.com
szymczyk is offline   0 Reply With Quote
Old Mar 12, 2012, 06:30 PM   #3
macuser1232
Thread Starter
macrumors 6502a
 
Join Date: Jan 2012
Quote:
Originally Posted by szymczyk View Post
You need to provide some more information for people to be able to help you. What version of Xcode are you using? Your mention of the Build and Run button tells me you're not using Xcode 4.

When you say the following:



Do you mean you created a C++ command-line tool project?

Are you able to build and run the project from Xcode's menus? Xcode 2 and 3 have a Build menu that has a Build and Run menu item.

If you click the link in my signature, you can find two articles that walk you through the creation of a C++ command-line application project in Xcode. One article covers Xcode 4 and the other covers earlier versions of Xcode.
I'm on xcode 3.2.6

----------

Quote:
Originally Posted by macuser1232 View Post
I'm on xcode 3.2.6
if i just start a new project and don't edit the default coding at all it still won't let me build and run the project.
macuser1232 is offline   0 Reply With Quote
Old Mar 13, 2012, 01:50 PM   #4
szymczyk
macrumors regular
 
Join Date: Mar 2006
If you create a different type of project, such as a Cocoa application, are the menu items in the Build menu enabled so you can build the project? Have you tried restarting Xcode? Something could have been messed up that a restart would fix.
__________________
Mark Szymczyk
Author, Xcode Tools Sensei
http://www.meandmark.com
szymczyk is offline   0 Reply With Quote
Old Mar 13, 2012, 07:02 PM   #5
macuser1232
Thread Starter
macrumors 6502a
 
Join Date: Jan 2012
Quote:
Originally Posted by szymczyk View Post
If you create a different type of project, such as a Cocoa application, are the menu items in the Build menu enabled so you can build the project? Have you tried restarting Xcode? Something could have been messed up that a restart would fix.
I tried creating a different type of project and it still didn't let me build and run. Also by restarting do you mean quitting the application and then starting it again and trying? Because, I have already done that several times.
macuser1232 is offline   0 Reply With Quote
Old Mar 13, 2012, 08:04 PM   #6
szymczyk
macrumors regular
 
Join Date: Mar 2006
Quote:
Originally Posted by macuser1232 View Post
by restarting do you mean quitting the application and then starting it again and trying?
Yes.

The only suggestion I can give is to uninstall Xcode and reinstall it. Instructions on how to uninstall Xcode are in the About Xcode and iOS SDK document that comes with Xcode. If uninstalling and reinstalling doesn't work, ask on Apple's Xcode mailing list. Some of Apple's Xcode engineers answer questions on the mailing list.
__________________
Mark Szymczyk
Author, Xcode Tools Sensei
http://www.meandmark.com
szymczyk is offline   0 Reply With Quote

Reply
MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting 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

Forum Jump

Similar Threads
thread Thread Starter Forum Replies Last Post
iPhone won't let me restore; device not eligible for requested build? IverTHPS2 iPhone Tips, Help and Troubleshooting 17 Feb 7, 2013 01:41 PM
Help, Mac won't let me run programs RockPortTech MacBook Pro 5 Mar 1, 2012 07:23 PM
itunes won't let me drag and drop songs anywhere JJBro1 Mac OS X 3 Jan 13, 2012 03:14 AM
applescript and xcode build and run error mrzman Mac Programming 2 May 13, 2010 07:23 AM
java: How do you build and run your project inside xcode instead of terminal? macman2790 Mac Programming 2 Jan 18, 2007 10:51 AM


All times are GMT -5. The time now is 08:11 AM.

Mac Rumors | Mac | iPhone | iPhone Game Reviews | iPhone Apps

Mobile Version | Fixed | Fluid | Fluid HD
Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

Privacy / DMCA contact / Affiliate and FTC Disclosure
Copyright 2002-2013, MacRumors.com, LLC