All Questions

Tagged with
Filter by
Sorted by
Tagged with
1270 votes
42 answers
1.1m views

How can I develop for iPhone using a Windows development machine?

Is there any way to tinker with the iPhone SDK on a Windows machine? Are there plans for an iPhone SDK version for Windows? The only other way I can think of doing this is to run a Mac VM image on a ...
909 votes
25 answers
554k views

Xcode error "Could not find Developer Disk Image"

When attempting to run a build on a connected iOS device in Xcode I get the error: Could not find Developer Disk Image I saw that there was a public beta for Xcode, so I installed it. One of the ...
Nathan Kramer's user avatar
588 votes
21 answers
358k views

Is it possible to disable the network in iOS Simulator?

I am trying to debug some inconsistent behaviour I am seeing in an application that gets its primary data from the Internet. I don't see the issues in the simulator, just on the device, so I'd like ...
Paul Hammond's user avatar
  • 6,366
570 votes
24 answers
234k views

How to lose margin/padding in UITextView

I have a UITextView in my iOS application, which displays a large amount of text. I am then paging this text by using the offset margin parameter of the UITextView. My problem is that the padding of ...
sniurkst's user avatar
  • 7,282
550 votes
32 answers
411k views

How to determine the current iPhone/device model?

Is there a way to get the device model name (iPhone 4S, iPhone 5, iPhone 5S, etc) in Swift? I know there is a property named UIDevice.currentDevice().model but it only returns device type (iPod touch,...
The Mach System's user avatar
530 votes
20 answers
308k views

Take screenshots in the iOS simulator

I want to take a screenshot of my iOS application when it is running in the simulator, and save the screenshot on my Mac. How can I do this?
Shreyash Mahajan's user avatar
523 votes
12 answers
281k views

Missing Compliance status in TestFlight

When I added my latest build for internal testing with TestFlight, I saw that it had a "Missing Compliance" status. Is this a major problem? Why does this appear? How can I resolve this ...
Chandan Jee's user avatar
  • 5,690
513 votes
8 answers
156k views

iPad Multitasking support requires these orientations

I'm trying to submit my universal iOS 9 apps to Apple (built with Xcode 7 GM) but I receive this error message for the bundle in iTunes Connect, just when I select Submit for Review: Invalid Bundle. ...
Cosmin's user avatar
  • 6,823
511 votes
35 answers
223k views

How to navigate through textfields (Next / Done Buttons)

How can I navigate through all my text fields with the "Next" Button on the iPhone Keyboard? The last text field should close the Keyboard. I've setup the IB the Buttons (Next / Done) but now I'm ...
phx's user avatar
  • 5,937
504 votes
30 answers
150k views

How to develop or migrate apps for iPhone 5 screen resolution?

The new iPhone 5 display has a new aspect ratio and a new resolution (640 x 1136 pixels). What is required to develop new or transition already existing applications to the new screen size? What ...
Lukasz's user avatar
  • 19.9k
435 votes
42 answers
262k views

Xcode "Device Locked" When iPhone is unlocked

When I tried to build and run, Xcode said my device was locked. I looked at my iPhone, and it's not locked at all. How do I fix this?
Faisal Syed's user avatar
  • 4,421
383 votes
23 answers
199k views

Images can't contain alpha channels or transparencies

Apple has released new version of iTunes Connect & I got an error message when I tried to set Screenshots on itunes connect for my app. "Images can't contain alpha channels or transparencies."
Yasika Patel's user avatar
  • 6,386
376 votes
31 answers
199k views

Determine device (iPhone, iPod Touch) with iOS

Is there a way to determine the device running an application. I want to distinguish between iPhone and iPod Touch, if possible.
Rob's user avatar
  • 5,588
375 votes
10 answers
315k views

Remove or uninstall library previously added : cocoapods

I added an external framework via cocoapods into my iOS application. How can i remove that library from the project?
Lithu T.V's user avatar
  • 20k
370 votes
6 answers
172k views

Proper way to renew distribution certificate for iOS

My distribution certificate is expiring on June 7th, along with all of my provisioning files. How do I properly renew it? Should I revoke it now and request a new one? If I do that than will all my ...
user1413558's user avatar
  • 3,899
367 votes
24 answers
214k views

How to use Auto Layout to move other views when a view is hidden?

I have designed my custom Cell in IB, subclassed it and connected my outlets to my custom class. I have three subviews in cell content which are: UIView (cdView) and two labels (titleLabel and ...
Guferos's user avatar
  • 4,357
362 votes
48 answers
213k views

Xcode error: Failed to prepare device for development

I have updated to Xcode 12.3 beta. device version is 14.2, but Xcode complaining: Errors were encountered while preparing your device for development. Please check the Devices and Simulators Window. ...
Hashem Aboonajmi's user avatar
358 votes
16 answers
258k views

How do I draw a shadow under a UIView?

I'm trying to draw a shadow under the bottom edge of a UIView in Cocoa Touch. I understand that I should use CGContextSetShadow() to draw the shadow, but the Quartz 2D programming guide is a little ...
Fraser Speirs's user avatar
349 votes
20 answers
146k views

iOS UIImagePickerController result image orientation after upload

I am testing my iPhone application on an iOS 3.1.3 iPhone. I am selecting/capturing an image using a UIImagePickerController: UIImagePickerController *imagePicker = [[UIImagePickerController alloc] ...
james's user avatar
  • 26.2k
348 votes
42 answers
191k views

library not found for -lPods

I got an error when archiving a project. This is my environment. Mac OS Lion Xcode 4.3.1 iOS SDK 5.1 The project deployment target is: IPHONEOS_DEPLOYMENT_TARGET 3.2 The error shows: ld: library ...
angelokh's user avatar
  • 9,328
346 votes
33 answers
124k views

What are best practices that you use when writing Objective-C and Cocoa? [closed]

I know about the HIG (which is quite handy!), but what programming practices do you use when writing Objective-C, and more specifically when using Cocoa (or CocoaTouch).
344 votes
17 answers
276k views

iPhone App Icons - Exact Radius?

I'm trying to create the icon for my iPhone app, but don't know how to get the exact radius that the iPhone's icons use. I've searched and searched for a tutorial or a template but can't find one. I'...
Frank Barson's user avatar
  • 3,469
343 votes
22 answers
239k views

Color Tint UIButton Image

I noticed that when I place a white or black UIImage into a UISegmentedControl it automatically color masks it to match the tint of the segmented control. I thought this was really cool, and was ...
Logan Shire's user avatar
  • 5,063
339 votes
9 answers
236k views

Programmatically get own phone number in iOS

Is there any way to get own phone number by standard APIs from iPhone SDK?
Vadim's user avatar
  • 9,463
327 votes
15 answers
191k views

How to hide 'Back' button on navigation bar on iPhone?

I added a navigation control to switch between views in my app. But some of the views shouldn't have 'Back' (the previous title) button. Any ideas about how to hide the back button?
Chilly Zhong's user avatar
  • 16.8k
324 votes
18 answers
203k views

Detect current device with UI_USER_INTERFACE_IDIOM() in Swift

What is the equivalent of UI_USER_INTERFACE_IDIOM() in Swift to detect between iPhone and iPad? I get an Use of unresolved identifier error when compiling in Swift.
Berry Blue's user avatar
  • 15.8k
319 votes
7 answers
165k views

Why does viewWillAppear not get called when an app comes back from the background?

I'm writing an app and I need to change the view if the user is looking at the app while talking on the phone. I've implemented the following method: - (void)viewWillAppear:(BOOL)animated { [...
Philip Walton's user avatar
317 votes
23 answers
244k views

UITableview: How to Disable Selection for Some Rows but Not Others

I am displaying in a group tableview contents parsed from XML. I want to disable the click event on it (I should not be able to click it at all) The table contains two groups. I want to disable ...
Warrior's user avatar
  • 39.2k
314 votes
35 answers
189k views

Adding images or videos to iPhone Simulator

I am trying to use UIImagePickerController with UIImagePickerControllerSourceTypePhotoLibrary, but it says, "No photos". Where does the simulator get the images from? Where should I copy the images so ...
Vijayeta's user avatar
  • 5,615
307 votes
15 answers
530k views

Capturing mobile phone traffic on Wireshark

How can I capture mobile phone traffic on Wireshark?
Xara's user avatar
  • 8,938
304 votes
8 answers
90k views

How to Sync iPhone Core Data with web server, and then push to other devices? [closed]

I have been working on a method to sync core data stored in an iPhone application between multiple devices, such as an iPad or a Mac. There are not many (if any at all) sync frameworks for use with ...
Jason's user avatar
  • 14.6k
302 votes
24 answers
156k views

How to detect iPhone 5 (widescreen devices)?

I've just upgraded to Xcode 4.5 GM and found out that you can now apply the '4" Retina' size to your view controller in the storyboard. Now if I want to create an application that runs on both ...
Finn Gaida's user avatar
  • 4,010
299 votes
10 answers
231k views

How can we programmatically detect which iOS version is device running on? [duplicate]

I want to check if the user is running the app on iOS less than 5.0 and display a label in the app. How do I detect which iOS is running on user's device programmatically? Thanks!
meetpd's user avatar
  • 9,219
294 votes
24 answers
182k views

Creating a left-arrow button (like UINavigationBar's "back" style) on a UIToolbar

I'd love to create a "back" left-arrow-bezel button in a UIToolbar. As far as I can tell, the only way to get one of these is to leave UINavigationController at default settings and it uses one for ...
Marco's user avatar
  • 15k
293 votes
24 answers
255k views

Proper way to exit iPhone application?

I am programming an iPhone app, and I need to force it to exit due to certain user actions. After cleaning up memory the app allocated, what's the appropriate method to call to terminate the ...
user21293's user avatar
  • 6,479
291 votes
21 answers
315k views

How to add line break for UILabel?

Let see that I have a string look like this: NSString *longStr = @"AAAAA\nBBBBB\nCCCCC"; How do I make it so that the UILabel display the message like this AAAAA BBBBB CCCCC I don't ...
Thang Pham's user avatar
  • 38.5k
287 votes
35 answers
322k views

Xcode 8 shows error that provisioning profile doesn't include signing certificate

Xcode 8 shows error that provisioning profile doesn't include signing certificate. This issue is with Xcode-8 only with Xcode 7, same provisioning profile showing related identified certificate.
Satish Mavani's user avatar
287 votes
6 answers
271k views

String replacement in Objective-C

How to replace a character is a string in Objective-C?
4thSpace's user avatar
  • 44k
286 votes
8 answers
166k views

Processing Symbol Files in Xcode

I was wondering if anyone could tell me what Xcode is actually doing when it says: "Processing Symbol Files" after plugging in your device?
Woodstock's user avatar
  • 22.5k
285 votes
38 answers
226k views

Detect if the device is iPhone X

My iOS app uses a custom height for the UINavigationBar which leads to some problems on the new iPhone X. Does someone already know how to reliable detect programmatically (in Objective-C) if an app ...
Andrei Herford's user avatar
285 votes
6 answers
137k views

What does ENABLE_BITCODE do in xcode 7?

I have a problem with the embedded bitcode term. What is embedded bitcode? When to enable, ENABLE_BITCODE in new Xcode? What happens to the binary when enabled, ENABLE_BITCODE in Xcode 7?
damithH's user avatar
  • 5,158
283 votes
17 answers
94k views

Where are iOS simulator screenshots stored?

I have saved some screenshots in the iPhone Simulator running iOS 5, but I can't find them. I had this problem before, and it took me frickin' ages to find them in the file system. Is this so simple ...
Flyingkiwi's user avatar
  • 3,146
282 votes
21 answers
269k views

Aligning text and image on UIButton with imageEdgeInsets and titleEdgeInsets

Historic question. Note that 15 years later, .imagePadding is the space between the image and label. Original question: I would like to place an icon left of the two lines of text such that there's ...
Justin Galzic's user avatar
281 votes
14 answers
215k views

Cocoa Touch: How To Change UIView's Border Color And Thickness?

I saw in the inspector that I can change the background color, but I'd like to also change the border color and thickness, is this possible?
Shai UI's user avatar
  • 51.2k
277 votes
6 answers
91k views

Warning: The Copy Bundle Resources build phase contains this target's Info.plist file

I've separated a project into two builds and given each of them a plist file. Everything works fine, but I keep getting this build warning: Warning: The Copy Bundle Resources build phase contains ...
nevan king's user avatar
  • 113k
275 votes
7 answers
143k views

How to store custom objects in NSUserDefaults

Alright, so I've been doing some poking around, and I realize my problem, but I don't know how to fix it. I have made a custom class to hold some data. I make objects for this class, and I need to ...
Ethan Mick's user avatar
  • 9,537
272 votes
23 answers
285k views

How to get device make and model on iOS?

I was wondering if it's possible to determine what kind of iPhone (for example) the currentdevice is? I know it's possible to get the model through NSString *deviceType = [[UIDevice currentDevice] ...
Nathan Fraenkel's user avatar
271 votes
6 answers
127k views

Always pass weak reference of self into block in ARC?

I am a little confused about block usage in Objective-C. I currently use ARC and I have quite a lot of blocks in my app, currently always referring to self instead of its weak reference. May that be ...
the_critic's user avatar
  • 12.8k
270 votes
10 answers
186k views

How to disable scrolling in UITableView table when the content fits on the screen

I have a few (grouped style) tables in my iphone app (only on part of the screen and added with Interface Builder though, not subclassed from UITableViewController) that 80% of the time are small and ...
Ginny's user avatar
  • 3,111
265 votes
8 answers
162k views

iOS 6 apps - how to deal with iPhone 5 screen size? [duplicate]

Possible Duplicate: How to develop or migrate apps for iPhone 5 screen resolution? I was just wondering with how should we deal with the iPhone 5 bigger screen size. As it has more pixels in ...
jturolla's user avatar
  • 6,626

1
2 3 4 5
2005