Post

Replies

Boosts

Views

Activity

current time
I used the Date class such as "currentTime = Date()", but I get a date that is off by 5 hours exactly. How do I get the current time? Is there a time zone setting I have to set?
18
0
5.6k
Aug ’23
app logging
Does Cocoa Touch provide a convenient way for apps to perform logging? Perhaps something similar to the print() command except it is kept after the app is installed?
Topic: UI Frameworks SubTopic: UIKit Tags:
6
0
1.7k
Jan ’22
What happens when I delete an App ID in my developer account?
I clicked the delete button to an App ID in my developer account and I got a message saying "All certificates associated with the App ID will be deleted and any provisioning profiles associated with this App ID will be invalidated." Why would the entire provisioning profile be invalidated? What about the other App IDs in that provisioning profile? Does that mean I wouldn't be able to use the provisioning profile for those other App IDs at all?
2
0
3.3k
Feb ’21
Does unifiedContacts(matching:keysToFetch:) return only unified contacts and leave out non-unified contacts?
When I use the Contacts Framework with Swift for iOS 15 using Xcode 13, when I use CNContactStore instance method unifiedContacts(matching:keysToFetch:), what happens to those CNContact objects that are not linked with any other CNContact objects, would they be returned as non-unified contacts, or would they be left out since they are non-unified contacts?
2
0
881
Nov ’21
Has anyone figured out how to create a CNContainer in an iOS device?
Apple Documentation says that there is only one CNContainer in an iOS device of type local. Creating a container of type exchange requires using Exchange, and creating a container of type cardDAV requires a server also. Is there any way to create a container of type unassigned? I would need to do this programmatically in Swift to use in my iOS app. This question and the posts it mentions give no answer.
2
0
1.9k
Dec ’22
How do I make a link to a specific answer instead of the entire post?
How do I get the answer id of an answer in a thread? I would like to know how to create a link to a specific answer of a post so I can refer to a specific answer rather than to the top of the page of the post. I noticed one link went to this address - https://developer.apple.com/forums/thread/67535?answerId=195112022#195112022. That's where I learned about the "answerId" item.
2
0
664
Mar ’22
Why does a participant of a share not have a record referenced by the root record?
I am able to share a record in CloudKit using the instructions in the Apple Documentation, including the CloudKitShare sample, but when another user accepts the share, only the root record is saved in the sharedDatabase. There is supposed to be another record that has a reference to the root record. I'm not sure what code to include in this post. Perhaps someone can tell me that much or know of a common programmer mistake that causes this error. Here is the basic code, after I have removed code not essential to the problem, to make my code easier to read. @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate {     func application(_ application: UIApplication, userDidAcceptCloudKitShareWith cloudKitShareMetadata: CKShare.Metadata) {         let container = CKContainer(identifier: cloudKitShareMetadata.containerIdentifier)         let acceptSharesOperation = CKAcceptSharesOperation(shareMetadatas: [cloudKitShareMetadata])         container.add(acceptSharesOperation)     } }
2
0
475
Apr ’22
Is it safe to update to macOS 12.3.1 without disrupting Xcode 13.3?
Before I update my macOS to 12.3.1, form 12.3, I want to know if anyone has installed it and if it interfered with Xcode. I heard that macOS updates faster than Xcode so that at times the new macOS requires a new Xcode that hasn't been released yet. I checked Mac App Store, and there isn't a version released after Xcode 13.3 (13E113).
2
0
1k
Apr ’22