Learn about closures and how to write closures in swift

  What are closures? As per apple documentation, closures are self contained blocks of  functionality that can be passed around code. In swift these are similar to what we called blocks in objective c and lambda in other languages. The definition is quiet complex to understand, so in simple words we can define closure as […]

Learn about closures and how to write closures in swift Read More »

Set placeholder to UITextView in swift

    Introduction to tutorial – set placeholder to UITextView: Placeholder is a property associated with input UI components that works as a hint to the user in mobile app development. UITextField has placeholder property but there is no property for setting placeholder to UITextView in swift. So for adding placeholder to UITextView , we

Set placeholder to UITextView in swift Read More »

Draw route on iOS map using MKDirections in swift

Introduction to draw route on iOS map (MapKit) using MKDirections in swift4 In this tutorial, we are going to learn how to to draw route on MapKit (apple map) between two locations using swift language. We will use MKAnnotation’s to draw pins for source and destination. For getting route, we will use MKDirection class and

Draw route on iOS map using MKDirections in swift Read More »

Add custom checkbox on UITableViewCell

Add custom checkbox on UITableViewCell or UITableView in swift In this tutorial, we are going to learn about, how we can add custom checkbox on UItableViewCell or UITableView in swift. And we also perform IBAction on our custom checkbox placed on UITableViewCell. We will place UIButton on UITableViewCell that will act as checkbox for our

Add custom checkbox on UITableViewCell Read More »

Email address validation in swift

Introduction to email address validation in swift In this tutorial, we will learn how to add email address validation in swift4. We will use NSPredicate with regex to validate email of format “[email protected]”. Also, how to validate an empty UITextField in swift using guard statement. Let us jump to the tutorial and learn how to

Email address validation in swift Read More »

How to create csv file in swift programmatically

Introduction to how to create CSV file in swift programmatically As the heading of this tutorial says, we are going to learn how to create csv file in swift programmatically. CSV(comma separated values) or excel files as they are commonly known are not a difficult task in iOS app development using swift. In this post,

How to create csv file in swift programmatically Read More »