Questions tagged [xcode4]

Xcode 4, released in June 2011, is Apple's integrated development environment (IDE) for Mac OS X and iOS. This tag should only be used for questions about this specific version of Xcode, and not for general Mac or iOS programming topics. Use [cocoa] for Mac programming questions, or [cocoa-touch] for iOS (formerly iPhone OS) programming questions.

Xcode 4 is the successor to Xcode 3, the main development tool for developing software under Mac OS X, targeting Mac OS and iOS. It was introduced to the developer community at Apple WWDC 2010, and the final release was published in March 2011. It was replaced by Xcode 5 in September 2013.

References

See for more information.

5408 questions
77
votes
13 answers

Xcode 4 code sense is not working

I am running a "old" Xcode 3 project in Xcode 4 and code sense is not working for my own classes. I have tried following: Clean/rebuild Remove Derived Data Installing 4.3 documentation Restart Without any luck. Sometimes the code sense works but…
Okku
  • 1,167
  • 1
  • 13
  • 23
77
votes
2 answers

iPhone ad hoc build using Xcode 4

I just switched to Xcode 4 and need to make an ad hoc build so my customer can test my app. Yet every tutorial I find is based on Xcode 3 and I can't seem to find my way with Xcode 4 on similar settings and actions I need to do. Is there a tutorial…
eMich
  • 1,736
  • 1
  • 14
  • 16
76
votes
2 answers

Xcode intellisense meaning of letters in colored boxes like f,T,C,M,P,C,K,# etc

Recently, I have started using Xcode 4 for developing iOS apps. In Xcode intellisense's autocomplete box, there are some letters in colored boxes before every suggestion. I know that they represent the property of the word we are typing like…
hiprakhar
  • 1,007
  • 3
  • 12
  • 15
76
votes
6 answers

Linking a static library to an iOS project in Xcode 4

I have a project (AQGridView) that compiles to a static library, but I can't seem to add it to my project. Dragging in the project to my project creates a workspace, and if I try to link the libAQGridView.a file from the DerivedData directory it…
Matt Hudson
  • 7,329
  • 5
  • 49
  • 66
75
votes
12 answers

Code Sign error: Provisioning profile can't be found

I have been working the whole day to try to build my app on my device. I get this error when I try to build on my device. I have been reading about this problem but do not really understand how to fix it. The following is where I would believe the…
PeterK
  • 4,243
  • 4
  • 44
  • 74
74
votes
3 answers

How to change the Class Prefix in Xcode 4?

When creating a project in Xcode 4, it asks what Class prefix to add to all new files. Is there a way to change (or remove) this, after a project is already started?
TigerCoding
  • 8,710
  • 10
  • 47
  • 72
73
votes
1 answer

Is there a keyboard shortcut for locating the current file in Project Navigator?

Is there a way to easily get the current file in the Editor pane selected in the Project Navigator without the need to expand all folders (if the file is buried deep down somewhere)? I know you can see the location in your project using the "bread…
Niels R.
  • 7,260
  • 5
  • 32
  • 44
72
votes
5 answers

Is there a way to jump to a specific method in Xcode?

I'm using Xcode 4.3 for Objective-C development. One feature that I like in other text editors (I know Xcode is an IDE), is jumping to a method definition within the same code file. For example if I'm in @implementation of Calculator and…
user171910
71
votes
1 answer

Where is the *goto line* command in Xcode4?

I couldn't find the goto line command in Xcode4. Where is it...?
eonil
  • 83,476
  • 81
  • 317
  • 516
69
votes
13 answers

Xcode can't open Info.plist -- error says "there is no such file"

I switched to Xcode 4 and loaded my project, which worked perfectly in Xcode 3. When I run it, I get an error that says: The file “Info.plist” couldn’t be opened because there is no such file. I have looked at the file in Xcode and it is there. So…
Octavia Togami
  • 4,186
  • 4
  • 31
  • 49
68
votes
5 answers

Is it possible to view the contents of files in the iOS Application sandbox while debugging?

I'd like to check the contents of an XML file at a specific point of execution while debugging in Xcode. Is it possible to view the contents of the file, either through the Organizer (I'm debugging using actual hardware devices, not the simulator),…
Will Pragnell
  • 3,073
  • 1
  • 20
  • 21
68
votes
22 answers

error: failed to attach to process ID 0

I have been reading the forums and so far none of the solutions suggested works for me. I'm running Xcode 4.4.1 and testing in iPhone 5.1 simulator. The simulator won't open the apps anymore and I'm getting the above error. Any thoughts or solutions…
user1661826
  • 723
  • 1
  • 6
  • 7
67
votes
8 answers

How can I find a line number in Xcode?

I have a function in my *.m file - (void)myFunction {} How can I find the line number this function?
Voloda2
  • 12,359
  • 18
  • 80
  • 130
67
votes
13 answers

Localised Strings Xcode 4 ... Copy .strings file Error Validation failed

How do I define localised strings in Xcode 4? I assumed I could just add languages to InfoPlist.strings using the "Localization" property (File inspector, right panel). ...and then type in the "key" = "value"s in each localised version. But I can't…
user433579
  • 1,223
  • 1
  • 10
  • 17
67
votes
5 answers

Can I add my own code snippets to xcode 4?

It'd be really handy to have collection KVC accessor snippets in xcode, as they're a pain to do by hand. Has anyone who's been using 4 for a while worked out how to add new ones? (...we're allowed to talk about it now, right?)
Chris Devereux
  • 5,453
  • 1
  • 26
  • 32