iOS Development is easy with XCode, Swift3, UITableView, cocatouch, let's build iPhone, iPad and Macbook Applications.

Change iPhone UISlider bar image

I’m using a UISlider in my app but I’d like to use a custom “look-and-feel” for it. I have changed the thumb to my own image but is there a way to change the bar also? I have a bar image I would like to use but can’t see how to do this. I have […]

Objective C – Assign, Copy, Retain

I’m new to Objective C. I have basic knowledge in C, including the concept of pointers. I have two basic questions: Can someone explain the difference between assign,copy, and retain with some analogy? How do you handle a function which returns pointer variable, and how do you perform messaging through a return pointer?

“From View Controller” disappears using UIViewControllerContextTransitioning

I got one problem and i have described it below. I am using UIViewControllerContextTransitioning for custom transitions. I have 2 view controllers , first view controller and second view controller. Now i want to add secondview controller on first view controller with animation. I have achieved it, now I have secondview controller transparent , so […]

Changing root view controller of a iOS Window

Is the root view controller of a iOS Window usually initialized once in the beginning to a tab bar controller or navigation controller? Is it okay to change the root view controller multiple times within an app? I have a scenario where the top view is different based on user action. I was thinking of […]

iOS app error – Can't add self as subview

I received this crash report, but I don’t know how to debug it. Fatal Exception NSInvalidArgumentException Can’t add self as subview 0 … CoreFoundation __exceptionPreprocess + 130 1 libobjc.A.dylib objc_exception_throw + 38 2 CoreFoundation -[NSException initWithCoder:] 3 UIKit -[UIView(Internal) _addSubview:positioned:relativeTo:] + 110 4 UIKit -[UIView(Hierarchy) addSubview:] + 30 5 UIKit __53-[_UINavigationParallaxTransition animateTransition:]_block_invoke + 1196 6 […]

How do I create a category in Xcode 6 or higher?

I want to create a category on UIColor in my app using Xcode 6. But the thing is that in Xcode 6 there is no Objective-C category file template. Is there any option to create a category in Xcode 6?

Is it possible to reset the privacy settings in iOS?

In order to test access granting to the iOS calendar, I need to reset the privacy settings on my test device. However, every time I install it on the device it remembers the old privacy settings and does not show the alert view to ask me if I grant access. Deleting the app and reinstalling […]

Prompt when trying to dial a phone number using tel:// scheme on iOS 10.3

After updating to 10.3, my app no longer automatically dials a phone number after pressing the call button in my app using the openURL: options: completionHandler: method. Instead, a prompt comes up every time to confirm the user’s intentions. As per the Apple Documentation: The tel URL scheme is used to launch the Phone app […]

NSLog on devices in iOS 10 / Xcode 8 seems to truncate? Why?

Why the console output shows incomplete in Xcode 8 / iOS 10?

NSURLConnection sendAsynchronousRequest can't get variable out of closure

I’m trying to get a simple text response from a PHP page using POST. I have the following code: func post(url: String, info: String) -> String { var URL: NSURL = NSURL(string: url)! var request:NSMutableURLRequest = NSMutableURLRequest(URL:URL) var output = “Nothing Returned”; request.HTTPMethod = “POST”; var bodyData = info; request.HTTPBody = bodyData.dataUsingEncoding(NSUTF8StringEncoding); NSURLConnection.sendAsynchronousRequest(request, queue: NSOperationQueue.mainQueue()){ […]