Questions tagged [ios8]

iOS 8 is the eighth version of Apple's iOS mobile operating system. It was announced at the company's Apple Worldwide Developers Conference (WWDC) on June 2, 2014 and was released to the public on September 17, 2014. The ios8 tag should be used for questions specific to Apple's iOS 8 operating system. General iOS questions should use the ios tag.

ios8
Filter by
Sorted by
Tagged with
686 votes
43 answers
188k views

iOS 8 UITableView separator inset 0 not working

I have an app where the UITableView's separator inset is set to custom values - Right 0, Left 0. This works perfectly in iOS 7.x, however in iOS 8.0 I see that the separator inset is set to the ...
user3570727's user avatar
  • 10.2k
623 votes
26 answers
285k views

Location Services not working in iOS 8

My app that worked fine on iOS 7 doesn't work with the iOS 8 SDK. CLLocationManager doesn't return a location, and I don't see my app under Settings -> Location Services either. I did a ...
ozg's user avatar
  • 17.6k
503 votes
25 answers
316k views

Capture iOS Simulator video for App Preview

Okay, so we can now submit video previews of our apps on the App Store. According to Apple we should do so with an iOS8 device and OSX 10.10. The problem is you have to have all the different devices (...
AXE's user avatar
  • 8,415
334 votes
4 answers
118k views

What's the difference between all the Selection Segues?

Show Show Detail Present Modally Popover presentation Custom What is the difference between them? I couldn't find any documentation on it. There used to be some which I found in a Google search, but ...
User's user avatar
  • 24.3k
322 votes
10 answers
101k views

Automatic Preferred Max Layout Width is not available on iOS versions prior to 8.0

I opened an existing iOS project with Xcode6 beta6, and Xcode lists the following warning for both Storyboard and Xib files: Automatic Preferred Max Layout Width is not available on iOS versions ...
mono's user avatar
  • 4,341
308 votes
35 answers
367k views

Reading in a JSON File Using Swift

I'm really struggling with trying to read a JSON file into Swift so I can play around with it. I've spent the best part of 2 days re-searching and trying different methods but no luck as of yet so I ...
Krivvenz's user avatar
  • 3,991
295 votes
16 answers
144k views

NSRange to Range<String.Index>

How can I convert NSRange to Range<String.Index> in Swift? I want to use the following UITextFieldDelegate method: func textField(textField: UITextField!, ...
János's user avatar
  • 34k
292 votes
28 answers
205k views

Error Domain=NSURLErrorDomain Code=-1005 "The network connection was lost."

I have an application which works fine on Xcode6-Beta1 and Xcode6-Beta2 with both iOS7 and iOS8. But with Xcode6-Beta3, Beta4, Beta5 I'm facing network issues with iOS8 but everything works fine on ...
VoidStack's user avatar
  • 3,058
246 votes
15 answers
344k views

How to create a String with format?

I need to create a String with format which can convert Int, Int64, Double, etc types into String. Using Objective-C, I can do it by: NSString *str = [NSString stringWithFormat:@"%d , %f, %ld, %@&...
Apurv's user avatar
  • 17.2k
234 votes
37 answers
309k views

Changing the Status Bar Color for specific ViewControllers using Swift in iOS8

override func preferredStatusBarStyle() -> UIStatusBarStyle { return UIStatusBarStyle.LightContent; } Using the above code in any ViewController to set the statusBar color to White for a specific ...
Anuj's user avatar
  • 7,047
231 votes
24 answers
412k views

How to call gesture tap on UIView programmatically in swift

I have a UIView and and I have added tap gesture to it: let tap = UITapGestureRecognizer(target: self, action: Selector("handleTap:")) tap.delegate = self myView.addGesture(tap) I am trying to call ...
George's user avatar
  • 3,690
230 votes
20 answers
115k views

iOS 8 Snapshotting a view that has not been rendered results in an empty snapshot

In iOS 8 I am having problem capturing images from camera till now I am using this code for UIImagePickerController *controller=[[UIImagePickerController alloc] init]; controller.videoQuality=...
souvickcse's user avatar
  • 7,782
210 votes
15 answers
104k views

registerForRemoteNotificationTypes: is not supported in iOS 8.0 and later

When trying to register for push notifications under iOS 8.x: application.registerForRemoteNotificationTypes(UIRemoteNotificationType.Alert | UIRemoteNotificationType.Badge | UIRemoteNotificationType....
Wojtek Turowicz's user avatar
194 votes
8 answers
103k views

How to enable native resolution for apps on iPhone 6 and 6 Plus?

Xcode 6 GM now includes simulators for iPhone 6 and 6 Plus, and by default they run apps in a scaled mode. To enable the new screen size I tried adding [email protected] which seems to do a part of ...
villapossu's user avatar
  • 2,747
192 votes
18 answers
258k views

NavigationBar bar, tint, and title text color in iOS 8

The background text in the status bar is still black. How do I change the color to white? // io8, swift, Xcode 6.0.1 override func viewDidLoad() { super.viewDidLoad() self....
AG1's user avatar
  • 6,686
187 votes
3 answers
132k views

Base64 Decoding in iOS 7+

I have Encoded text(NSString) using NSData Class new API which is Added in iOS7. using this - (NSData *)dataUsingEncoding:(NSStringEncoding)encoding; here is my code NSString *...
Sandeep Khade's user avatar
187 votes
14 answers
65k views

UISplitViewController in portrait on iPhone shows detail VC instead of master

I am using a Universal Storyboard in Xcode 6, targeting iOS 7 and above. I've implemented a UISplitViewController which is now natively supported on iPhone running iOS 8, and Xcode will automatically ...
Jordan H's user avatar
  • 54k
186 votes
18 answers
90k views

Is [UIScreen mainScreen].bounds.size becoming orientation-dependent in iOS8?

I ran the following code in both iOS 7 and iOS 8: UIInterfaceOrientation orientation = [[UIApplication sharedApplication] statusBarOrientation]; BOOL landscape = (orientation == ...
lwxted's user avatar
  • 2,429
171 votes
25 answers
214k views

Can I set the cookies to be used by a WKWebView?

I'm trying to switch an existing app from UIWebView to WKWebView. The current app manages the users login / session outside of the webview and sets the cookies required for authentication into the the ...
Col's user avatar
  • 2,320
164 votes
12 answers
230k views

Custom UITableViewCell from nib in Swift

I'm trying to create a custom table view cell from a nib. I'm referring to this article here. I'm facing two issues. I created a .xib file with a UITableViewCell object dragged on to it. I created a ...
Isuru's user avatar
  • 31k
161 votes
12 answers
56k views

Autoresizing issue of UICollectionViewCell contentView's frame in Storyboard prototype cell (Xcode 6, iOS 8 SDK) happens when running on iOS 7 only

I'm using Xcode 6 Beta 3, iOS 8 SDK. Build Target iOS 7.0 using Swift. Please refer to my problem step by step with screenshots below. I have a UICollectionView in Storyboard. 1 Prototype ...
thkeen's user avatar
  • 1,867
161 votes
5 answers
88k views

What is an "unwrapped value" in Swift?

I'm learning Swift for iOS 8 / OSX 10.10 by following this tutorial, and the term "unwrapped value" is used several times, as in this paragraph (under Objects and Class): When working with ...
Bigood's user avatar
  • 10.7k
156 votes
8 answers
42k views

Why is UICollectionViewCell's outlet nil?

I have created a custom UICollectionViewCell in Interface Builder, binded views on it to the class, and then when I want to use and set a string to the label on the string, tha label has a nil value. ...
János's user avatar
  • 34k
155 votes
25 answers
158k views

How to force view controller orientation in iOS 8?

Before iOS 8, we used below code in conjunction with supportedInterfaceOrientations and shouldAutoRotate delegate methods to force app orientation to any particular orientation. I used below code ...
Rashmi Ranjan mallick's user avatar
149 votes
28 answers
129k views

Launch Image does not show up in my iOS App

I want to get a simple launch screen to show in my app, built using Xcode 6.0.1. I have added a launch screen in two ways: As an XIB (with the default name, LaunchScreen.xib) and as a launchimage set ...
Eddie Hartman's user avatar
145 votes
3 answers
83k views

Obtain bundle identifier programmatically in Swift?

How can I get the bundle ID in Swift? Objective-C version: NSString *bundleIdentifier = [[NSBundle mainBundle] bundleIdentifier];
User's user avatar
  • 24.3k
144 votes
18 answers
97k views

Xcode 6 - How to pick signing certificate/provisioning profile for Ad-Hoc distribution?

To distribute the app to our testers we use Xcode, which we do using the following process: Archive application Distribute for Ad-Hoc Choose provisioning profile Save the .ipa to a folder But with ...
Legoless's user avatar
  • 11k
142 votes
7 answers
64k views

Rotation methods deprecated, equivalent of 'didRotateFromInterfaceOrientation'?

I'm trying to implement the new viewWillTransitionToSize method which has been introduced in iOS 8 (all other rotation methods have been deprecated). I'd like to know what the equivalent of ...
strange's user avatar
  • 9,684
137 votes
16 answers
119k views

Xcode 6 iPhone Simulator Application Support location

In Xcode 6, I have an app I'm using Core Data in, but there is no folder in Application Support for the iOS 8 iPhone Simulator. Where are my files and Core Data sqlite database being stored?
HGDev's user avatar
  • 2,212
137 votes
16 answers
152k views

Can't find keyplane that supports type 4 for keyboard iPhone-Portrait-NumberPad; using 3876877096_Portrait_iPhone-Simple-Pad_Default

I've downloaded iOS 8 Gold Master for the iPhone and the SDK. I tested the app and it works fine, except for one thing. I have a text field where a number pad will appear if the user wants to type ...
CRAZYSNAKE's user avatar
  • 1,373
134 votes
11 answers
116k views

Xcode iOS 8 Keyboard types not supported

I have a UITextField Ctrl-dragged as an @Outlet in my .swift class. Now in viewDidLoad i'm using this code self.myTextField.keyboardType = UIKeyboardType.DecimalPad When i launch my app on simulator ...
r4id4's user avatar
  • 5,997
132 votes
30 answers
75k views

UITableView dynamic cell heights only correct after some scrolling

I have a UITableView with a custom UITableViewCell defined in a storyboard using auto layout. The cell has several multiline UILabels. The UITableView appears to properly calculate cell heights, but ...
blackp's user avatar
  • 1,752
131 votes
10 answers
97k views

Is it possible to obtain a dynamic table view section header height using Auto Layout?

New in iOS 8, you can obtain 100% dynamic table view cells by simply setting the estimated row height, then layout your elements in the cell using Auto Layout. If the content increases in height, the ...
Jordan H's user avatar
  • 54k
129 votes
14 answers
87k views

WKWebView not loading local files under iOS 8

For previous iOS 8 betas, load a local web app (in Bundle) and it works fine for both UIWebView and WKWebView, and I even ported a web game using the new WKWebView API. var url = NSURL(...
Lim Thye Chean's user avatar
128 votes
24 answers
207k views

UIAlertController custom font, size, color

I am using new UIAlertController for showing alerts. I have this code: // nil titles break alert interface on iOS 8.0, so we'll be using empty strings UIAlertController *alert = [UIAlertController ...
Libor Zapletal's user avatar
127 votes
6 answers
57k views

What is the entry point of swift code execution?

There is no main() method in swift. The program must start the execution from somewhere. So what is the entry point of swift code execution and how is it decided?
Selvin's user avatar
  • 12.4k
120 votes
13 answers
197k views

How to present popover properly in iOS 8

I'm trying to add a UIPopoverView to my Swift iOS 8 app, but I am unable to access the PopoverContentSize property, as the popover does not show in the correct shape. my code: var popover: ...
Joris416's user avatar
  • 4,771
120 votes
7 answers
76k views

Adaptive segue in storyboard Xcode 6. Is push deprecated?

Xcode 6 interface builder by default has new checkbox "use size classes". It makes views adaptive. When I try to make segue between 2 views in my storyboard I have new options: instead old:...
John Kakon's user avatar
  • 2,541
115 votes
5 answers
65k views

Ask for User Permission to Receive UILocalNotifications in iOS 8

I have set up local notifications in the App Delegate Using this: - (void)applicationDidEnterBackground:(UIApplication *)application { UILocalNotification *notification = [[UILocalNotification ...
dannysandler's user avatar
  • 1,881
113 votes
11 answers
144k views

Disable a Button

I want to disable a button (UIButton) on iOS after it is clicked. I am new to developing for iOS but I think the equivalent code on objective - C is this: button.enabled = NO; But I couldn't do that ...
baranbaris's user avatar
  • 1,291
111 votes
13 answers
51k views

Enterprise App Update Distribution on iOS 8

I have an enterprise app that I'm distributing via an itms URL: itms-services://?action=download-manifest&url=itms-services://?action=download-manifest&url=https://$MY_PLIST_URL.plist On iOS ...
Patrick Perini's user avatar
110 votes
12 answers
120k views

Determine if the access to photo library is set or not - PHPhotoLibrary

With the new functionality in iOS 8, if you are using a camera in the app, it will ask for permission to access the camera and then when you try to retake the pic, it asks for permission to access ...
tech_human's user avatar
  • 6,780
110 votes
4 answers
77k views

Why can't I call the default super.init() on UIViewController in Swift?

I am not using a UIViewController from a storyboard and I want to have a custom init function where I pass in an NSManagedObjectID of some object. I just want to call super.init() like I have in ...
SirRupertIII's user avatar
  • 12.4k
107 votes
5 answers
74k views

What is the "right" way to handle orientation changes in iOS 8?

Can someone please tell me the "right" or "best" approach to working with portrait and landscape interface orientations in iOS 8? It seems that all the functions I want to use for that purpose are ...
RMP's user avatar
  • 5,111
106 votes
16 answers
55k views

Attributed string with custom fonts in storyboard does not load correctly

We are using custom fonts in our project. It works well in Xcode 5. In Xcode 6, it works in plain text, attributed string in code. But those attributed strings set in storyboard all revert to ...
Allen Hsu's user avatar
  • 3,534
104 votes
14 answers
17k views

Custom Font Sizing in Xcode 6 Size Classes not working properly with Custom Fonts

Xcode 6 has a new feature where fonts and font sizes in UILabel, UITextField, and UIButton can be set automatically based on the size class of the current device configuration, right in the storyboard....
mnemia's user avatar
  • 1,549
102 votes
26 answers
123k views

How to check validity of URL in Swift?

Trying to make an app launch the default browser to a URL, but only if the URL entered is valid, otherwise it displays a message saying the URL is invalid. How would I go about checking the validity ...
Clinton's user avatar
  • 1,031
100 votes
18 answers
48k views

iOS8 - constraints ambiguously suggest a height of zero

Has anyone got any idea how to debug this? Warning once only: Detected a case where constraints ambiguously suggest a height of zero for a tableview cell's content view. We're considering the ...
Chris's user avatar
  • 2,747
100 votes
7 answers
25k views

Sizing class for iPad portrait and Landscape Modes

I basically want to have my subviews positioned differently depending upon the orientation of the iPad (Portrait or Landscape) using Sizing Classes introduced in xcode 6. I have found numerous ...
neelIVP's user avatar
  • 1,001
99 votes
23 answers
117k views

Document directory path of Xcode Device Simulator

In iOS 7, the document directory of the iOS simulators can be found in: /Users/Sabo/Library/Application Support/iPhone Simulator/ However, in iOS 8 Beta Simulator, I can't find the corresponding ...
Fire Fist's user avatar
  • 7,052

1
2 3 4 5
186