iOS is the operating system for iPhone.

iOS Documentation

Posts under iOS tag

2,888 Posts
Sort by:
Post not yet marked as solved
2 Replies
1.1k Views
can we not post screenshot pics or videos to this forum? I see the icon to attach but when I click it nothing happens.
Posted
by
Post not yet marked as solved
4 Replies
1.5k Views
Has anyone tried to display a contact with the CNContactViewController making one of the email addresses highlighted? I tried it, but if I use the highlightPropertyWithKey method, the resulting controller is blank and the following message is logged:[CNUI ERROR] error calling service - Couldn’t communicate with a helper application.I also tried using the deprecated API (ABPersonViewController), and the result is exactly the same. It works fine on iOS8 though.Here's a sample code: func openAppleSeed(highlight:Bool) { let store = CNContactStore() let request = CNContactFetchRequest(keysToFetch: [CNContactEmailAddressesKey]); do { try store.enumerateContactsWithFetchRequest(request, usingBlock: { (contact:CNContact, stop:UnsafeMutablePointer<ObjCBool>) -> Void in for address in contact.emailAddresses { if address.value as! String == "John-Appleseed@mac.com" { do { let fullContact = try store.unifiedContactWithIdentifier(contact.identifier, keysToFetch: [CNContactViewController.descriptorForRequiredKeys()]) let vc = CNContactViewController(forContact: fullContact) vc.contactStore = store if highlight { vc.highlightPropertyWithKey(CNContactEmailAddressesKey, identifier: address.identifier) } self.navigationController?.pushViewController(vc, animated: true) return } catch { print("CATCHING (B)") } return; } } }) } catch { print("CATCHING (A)") } }Calling this function openAppleseed(highlight:false) works fine, but openAppleseed(highlight:true) generates the blank view controller and the log message mentioned aboved.I tested it with the latest beta (5), and both simulator and device. Same result. I am submitting a bug report now, but I was curious if anyone had the same issue. Any workarounds?Cheers.
Posted
by
Post not yet marked as solved
1 Replies
1.1k Views
I have downloaded Open Sans font and added all the .tff files into my Xcode project, and have checked the checkbox in "Target Membership" pane for each file. I have added the UIAppFontskey and values in Info.plist, and I am sure that the values are typo-free. Plus, the .tff files are added to "Copy Bundle Resources", and the custom font is showing up in Interface Builder. And then I changed the font of all the labels to Open Sans in the Interface Builder (no code).But when I run the app in the simulator, all the labels and buttons are showing the system font in ultra small sizes, like this:(picture)One thing to note is that I am using Xcode 7 beta 5, and the app's Base SDK is iOS 9.But why is there this problem? Is it a bug? Thanks!
Posted
by
Post not yet marked as solved
2 Replies
1k Views
Il manque le Français dans les langues . Le Français (Seul) . Pour que les applications peuvent être en Fançais !!!
Posted
by
Post not yet marked as solved
32 Replies
18k Views
I just filed a bug report for the Notes app as follows:Area: Notes Summary: When opening Notes with content that is larger than the open Notes App window, and attempting to edit the note, the entire note content scrolls automatically to the top although the cursor remains where text editing was inserted. Typing on the Smart Keyboard will allow text entry however the note insistently keeps scrolling to the top regardless of how often or how much text is entered into the note. Scrolling the note manually with your touch will stop the action from occurring, however that is intermittent and sometimes will scroll automatically as well. This issue will occur on both iPad and iPhone and regardless of the app is used full screen on the iPad or in Split Screen. When the Notes window is not focused and the user is engaging an app in the other split screen window, the Note window does not scroll, only when it is the focused App. Steps to Reproduce: 1. Open Notes2. Begin to edit the note by scrolling down and selecting text or placing your cursor to enter text.3. More likely to happen with a note which has enough text to enable scrolling of the note.Expected Results: The note body of text should not scroll while editing or entering text and should remain where placed either by scrolling to the place of entry with using touch or with moving the cursor with the direction keys of the Smart Keyboard. Actual Results: The note scrolls on its own without intervention. Version: IOS Beta 10.0(14A5261v) Configuration: iPad Pro 12.9" and iPhone 6S both with iOS beta 10.0
Posted
by
Post not yet marked as solved
3 Replies
20k Views
Is there a trick to getting debugging working on a Notification Service Extension? I've set breakpoints and none of them are getting hit. I can't even see my print statements in the console. I know something is happening in there, but I'm having to resort to monkeying with the content of the notification to figure out what is happening.Any ideas are helpful. Thanks!jared
Posted
by
Post not yet marked as solved
0 Replies
1.8k Views
Hello Guys,So for my iPhone 5 i'm nostalgic and I want to downgrade to the iOS 6.X.X version but is not possible so I've got an idea ! Please how I can create a custom firmware ? (I transfer icons, the design and the wallpapers of the iOS in the .ipsw of the iOS 9.3.3, roughly I have the complete design of the iOS 6 while being under the iOS 9.3.3!)Thanks for reply
Posted
by
Post marked as solved
4 Replies
6.3k Views
I'm looking for verification that this is correct, or to be corrected if this is wrong.Here's some code:#import <UserNotifications/UserNotifications.h>My AppDelegate.h has this:@interface AppDelegate : UIResponder <UIApplicationDelegate,UNUserNotificationCenterDelegate>And willFinishLaunchingWithOptions has this:UNUserNotificationCenter *center = [UNUserNotificationCenter currentNotificationCenter]; center.delegate = self; [center requestAuthorizationWithOptions:(UNAuthorizationOptionSound | UNAuthorizationOptionAlert | UNAuthorizationOptionBadge) completionHandler:^(BOOL granted, NSError * _Nullable error){ if( !error ) { NSLog( @"Push registration success." ); } else { NSLog( @"Push registration FAILED." ); } }];I'm getting the success message. So far, so good.In previous iOS versions, this delegate method was called:- (void)application:(UIApplication*)application didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceTokenFor iOS 10, I can get this method to be called if I add this to my requestAuthorizationWithOptions completionHandler:[[UIApplication sharedApplication] registerForRemoteNotifications];Is this the right way to do it? It seems incorrect because, when I do this, the old application:didReceiveRemoteNotification method is still firing, as-is the new center:didReceiveNotificationResponse.So, two things are firing now when a user taps a notification, and that does not seem right. However, if I remove the call to registerForRemoteNotifications, nothing fires when I receive a remote notification. And that makes sense because we have to have the device token to send to AWS, which facilitates delivery of notifications between us and Apple and Google.I don't see a way to get the device token from any of the new UserNotification classes, but it seems like I've done something wrong since UIApplicationDelegate and UNUserNotificationCenterDelegate are both reacting to push notifications.Any input?Thanks.
Posted
by
Post marked as solved
11 Replies
3.2k Views
When I clicked the NavigationBar in my App,it crashed.It only crashes in iOS 10 .The console log is:Assertion failure in -[UIGestureGraphEdge initWithLabel:sourceNode:targetNode:directed:], /BuildRoot/Library/Caches/com.apple.xbs/Sources/UIKit/UIKit-3599.6/Source/GestureGraph/UIGestureGraphEdge.m:25
Posted
by
Post not yet marked as solved
6 Replies
4.7k Views
How do I play spotify through my bluetooth headset? After upgrading, spotify only plays through my iphone even if the bluetooth headset is already connected. No option on spotify to play through the headset either.
Posted
by
Post not yet marked as solved
4 Replies
3.7k Views
Ever since updating to build iOS 10.1.1 (build 14b150) from iOS 10.1, battery life has drastically reduced. Previously with iOS 10.1, the battery lasted for around two days with one 100% charge. However, since updating to iOS 10.1.1 (build 14b150), battery is not lasting even one complete day. Sometimes, the battery drops around 10% in just 15minutes. This happening with no change in the software configuration or other settings.The battery life percentage displayed on the screen sometimes flickers and changes its value suddenly- upwards or downwards.
Posted
by
Post not yet marked as solved
11 Replies
45k Views
I've been experiencing an issue that has causing me a lot of problems, as various apps including Whatsapp, Telegram, Linkedin, Slack, Lastpass, and more will randomly log out, and reset back to their inital state as if I just installed it on a clean phone. Apps like Whatsapp and Telegram will have lost all of their chat history, even if it was backup up on iCloud.I'm at a total loss as to what might be causing this problem after restoring the phone multiple times (the last time without restoring to a backup).My phone is an iPhone 6S 64GB running iOS 10.2 (isn't BETA).
Posted
by
Post not yet marked as solved
29 Replies
44k Views
Is anybody else having a probelm pairing an Apple Pencil. I insert it into my new 2gen iPad Pro 12.9 and it briefly shows the dialog to Pair and then shows it connected, but then disconnects, and then I get an Error that the Pencil took to long to pair. Then it doesn't work.Am I alone in having this issue.Thanks,Nick
Posted
by
Post not yet marked as solved
15 Replies
17k Views
have noticed a few people with the same issue upon downgrading from iOS 11 beta 2 to iOS 10.3.2, in which trying to restore it becomes a endless loop of getting stuck at the recovery mode on the iPhone. I have found a potential way of fixing it. So if you are currently stuck in that recovery mode and its not going anywhere update your iPhone with the IOS 11 beta 1 via selecting the .ipsw. Once that has completed set up your iPhone but do not sign into your iCloud (note you can sign into wifi). Once you have set up your iPhone connect your iPhone to your computer. Then restore to iOS 10.3.3 from your download .ipsw file, set up your phone once more. After that restore agin to the iOS 10.3.2. Then it is recomended that you set up the iPhone but do not sign in quite yet but to confirm that it is at the correct version of iOS 10.3.2. After it has been confirmed factory reset your phone then set it up like normal. Congratulations you are back to iOS 10.3.2.What you will need:iOS 11.0 ipsw (restore image) iOS 10.3.3 ipsw(restore image) iOS 10.2.3 ipsw (please note I am on a iphone 7, you will have to select the correct files for your device)
Posted
by
Post not yet marked as solved
3 Replies
3.3k Views
iOS 11 adds smart quotes when typing. In macOS we can disable smart quotes on a NSTextView by setting:textView.automaticQuoteSubstitutionEnabled = NO;Neither UITextField or UITextView seem to have this property or the enabledTextCheckingTypes property. How can smart quotes be disabled on iOS 11?
Posted
by
Post not yet marked as solved
2 Replies
870 Views
Hey,during my drag, I need to update the UIDragPreview of the dragged item depending on it's location. I'm currently doing that by setting a new previewProvider each time the preview needs to be updated. When doing this, the current preview gets scaled down a little bit and the new one scales up, which looks a bit weird.Is there a better way to update the DragPreview? Or is there at least a way to get rid of the scaling?Best,Klemens
Posted
by
Post not yet marked as solved
9 Replies
15k Views
I have noticed various strange behaviours with the EAAccessory interface on iOS 11 (Betas 5 and 6 **update and now in the full production version 11.0.2 **)). I wonder if anyone else has had these issues? Everything worked OK on iOS 10.I am communicating with an accessory over a lightning socket (via a LAM), and get the following behaviour:1. Connecting to a device, EAAccessoryManager returns a connected EAAccessory (an EASession can be established, and data received, although this doesn't always happen), but then immediately disconnects from the EAAccessory, and then returns another connected EAAccessory.2. After opening an EASession on this new EAAccessory, no communications to the device is possible (sending data over the OutputStream doesn't result in the data getting to the accessory)3. On switching away from the app and back again, either:a) the app crashesorb) the input stream reports endEncountered and the output stream just seems to stop working, it never reports hasSpaceAvailable again.Some simplified code which illustrates this problem is below:import UIKitimport ExternalAccessoryclass ViewController: UIViewController, StreamDelegate { var connectedAccessory: EAAccessory? var eaSession: EASession? let supportedProtocolName = "My.Supported.Protocol" @IBOutlet weak var logTextView: UITextView! @IBOutlet weak var sendButton: UIButton! override func viewDidLoad() { super.viewDidLoad() log("loaded") // Do any additional setup after loading the view, typically from a nib. NotificationCenter.default.addObserver( forName: NSNotification.Name.EAAccessoryDidConnect, object: nil, queue: nil, using: accessoryConnected) NotificationCenter.default.addObserver( forName: NSNotification.Name.EAAccessoryDidDisconnect, object: nil, queue: nil, using: accessoryDisconnected) EAAccessoryManager.shared().registerForLocalNotifications() // Maybe we're already connected if let connectedAccessory = EAAccessoryManager.shared().connectedAccessories.first { self.connectedAccessory = connectedAccessory openSession() } } private func accessoryConnected(_ notification: Notification) { log("accessoryConnected") for accessory in EAAccessoryManager.shared().connectedAccessories { log("accessory: \(accessory)") log("") } // Connect to the first one (only expect there to be one for this test) self.connectedAccessory = EAAccessoryManager.shared().connectedAccessories.first openSession() } private func openSession() { guard let connectedAccessory = self.connectedAccessory else { return } self.eaSession = EASession( accessory: connectedAccessory, forProtocol: self.supportedProtocolName) openStream(eaSession?.inputStream) openStream(eaSession?.outputStream) } private func openStream(_ stream: Stream?) { stream?.delegate = self stream?.schedule(in: RunLoop.current, forMode: RunLoopMode.defaultRunLoopMode) stream?.open() } public func stream(_ stream: Stream, handle streamEvent: Stream.Event) { switch streamEvent { case Stream.Event.openCompleted: log("\(stream) openCompleted") if (eaSession?.inputStream?.streamStatus == Stream.Status.open && eaSession?.outputStream?.streamStatus == Stream.Status.open) { log("both input and output are open") } case Stream.Event.hasBytesAvailable: log("hasBytesAvailable") readAll() case Stream.Event.hasSpaceAvailable: log("hasSpaceAvailable") case Stream.Event.errorOccurred: log("\(stream) errorOccurred") closeSession() case Stream.Event.endEncountered: log("\(stream) endEncountered") closeSession() default: log("\(stream) default") closeSession() } } private func readAll() { let bufferSize = 128 var numberOfBytesRead = 0 repeat { var buffer = [UInt8](repeating: 0, count: bufferSize) numberOfBytesRead = eaSession!.inputStream!.read(&buffer, maxLength: buffer.count) if (numberOfBytesRead > 0) { log("read:\(buffer)") } } while (numberOfBytesRead == 128) } @IBAction func sendDataButtonPressed(_ sender: UIButton) { sendData() } private func sendData() { let data: [UInt8] = [1, 0, 0, 0, 16, 0, 0, 0, 0, 3] log("Sending: \(data)") self.eaSession?.outputStream?.write(data, maxLength: data.count) } private func closeSession() { closeStream(eaSession?.inputStream) closeStream(eaSession?.outputStream) eaSession = nil } private func closeStream(_ stream: Stream?) { stream?.close() stream?.remove(from: RunLoop.current, forMode: RunLoopMode.defaultRunLoopMode) stream?.delegate = nil } private func accessoryDisconnected(_ notification: Notification) { log("accessoryDisconnected") for accessory in EAAccessoryManager.shared().connectedAccessories { log("accessory: \(accessory)") log("") } guard let accessory = notification.userInfo?[EAAccessoryKey] as? EAAccessory else { return } log("disconnected accessory: \(accessory)") log("") closeSession() } private func log(_ msg: String) { self.logTextView.insertText("\(msg)\n") scrollLogToEnd() } private func scrollLogToEnd() { let stringLength = self.logTextView.text.characters.count self.logTextView.scrollRangeToVisible(NSMakeRange(stringLength - 1, 0)) } override func didReceiveMemoryWarning() { super.didReceiveMemoryWarning() // Dispose of any resources that can be recreated. }}
Posted
by
Post not yet marked as solved
5 Replies
3.8k Views
Hi,I have an App that is using geofencing and beacons since about one year in the app store. Recently I noticed more and more crashes and users are reporting of missing notifications upon geofence entry or exit ( I send a local notification upon entry or exit).so i suspect those crash reports are related to those user reports. The crash reports indicate memory management issues: lib dispatch.dylib _dispatch_callblock_and_releaseThese problem only occur since iOS 10.3. So I have some reports with iOS 10.3 but most of them with iOS 11. When I run the app in the simulator the memory usage is at around 50MB and does not increase. Even when I simulate geofence entry and exit etc it stays around the 50 MB usage.So my first question is it possible that the app crashes when not in foreground when it uses only 50MB?To investigate further I implemented the function func applicationDidReceiveMemoryWarning(_ application: UIApplication)And send a local notification when it get´s called. And indeed sometimes I sometimes get this warning and I myself have irregularities with the geofence enter and exit notifications.Now to further investigate I installed another App to monitor the same geofence (IFTTT). Here too I have irregularities with the geofence enter and exit notifications.Until now I was quite relaxed as I was sure it´s the early iOS 11 beta´s that have memory management issue. But i´m using the latest Beta (15A5372a) and I guess we are close to the final now. Also what worries me is that some users experience these issues also with iOS 10.3.Any ideas how to investigate this further or does anybody experience something similar?Very BestStephan
Posted
by
Post not yet marked as solved
14 Replies
26k Views
HI Folks , Thanks for helping, have not been able to get a redeem code to sign in on test flight , however did receive and responded to invitation on email.Thanks
Posted
by
Post not yet marked as solved
3 Replies
13k Views
I know that universal links were not working on redirection prior to some of the recent ios 11 version. I mean the following use case:1) having app that handles domain: "www.testdomain.com" universally.2) user clicks email tracking link (i.e. "http://tracking.com/someparameter") -> safari is opened.3) tracking page is the auto-redirected into universally supported link: "www.testdomain.com/somepage".But it seems like with one of the latest iOS update, universal links are now working on redirect.I could not find any official docs around universal links on redirect, so is it how universal links behave? If so, since what version is that enabled? Thank you,Alexey
Posted
by