The UITextChecker object can be used to spelling-check a string. In this
tutorial a few words will be displayed inside a Table View. When the words
are selected, they will be checked for spelling, the backgroundcolor will
change to green if the spelling is correct, otherwise the background color
will change to red. This tutorial is made in Xcode 7.2 for iOS 9.
Open Xcode and create a new Single View Application. For product name, use
IOS9TextFieldAlertControllerTutorial and then fill out the Organization
Name and Organization Identifier with your customary values. Enter Swift as
Language and make sure only iPhone is selected in Devices.
Over the last few weeks we have been manually positioning everything in our game via code. Which is not a bad thing. In fact, it's important to know how to add objects to our scene via code. However, there comes...
I was is need of a Alert Controller thet was self dismissed. Here’s how I did that: Create a Single View Application. Define a global variable for the UIAlertController. let alertView = UIAlertController(title: "Wait 3 seconds", message: "This message will selfdiscruct after... Continue Reading →
I wanted some code to be triggered after a timer was done. Here’s a simple example of that and how I did it. Add a Single View Application. Create a label to see that our code works, change it’s label... Continue Reading →
The iPhone has the built-in ability to alert the user with a vibration.
Sting the System Sound services the vibration can be triggered. In this
tutorial the vibration will be triggered 5 times. This tutorial is made
with Xcode 7 and built for iOS9. Note this app is built for a real devices,
since the iOS Simulator doesn't have vibration.
I was recently in need of adding a volume control to an App that uses AVPlayer to play a stream from Internet. Here’s I solved it (excluding all the parts besides the volume control). In your project you already have... Continue Reading →
Here’s how to get rid of the “App Transport Security has blocked a cleartext HTTP (http://) resource load since it is insecure. Temporary exceptions can be configured via your app’s Info.plist file.” error message when using http in your code.... Continue Reading →
Here’s a way of doing that. Create a new Single View Application. Drag and drop the images you want to your project and name them Bars-0, Bars-1 and so on. (In my project they are called Bars-0, Bars-1, Bars-2 and Bars-3). I... Continue Reading →
Here’s an example on how to add an Interstitial iAd once the App is started and an iAd i available. Create a new Single View Application. In ViewController.swift, import iAd. import iAd Make sure your ViewController is a delegate for your ad. class... Continue Reading →