Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Learn Swift by Building Applications

You're reading from   Learn Swift by Building Applications Explore Swift programming through iOS app development

Arrow left icon
Product type Paperback
Published in May 2018
Publisher Packt
ISBN-13 9781786463920
Length 366 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Authors (2):
Arrow left icon
Giordano Scalzo Giordano Scalzo
Author Profile Icon Giordano Scalzo
Giordano Scalzo
Emil Atanasov Emil Atanasov
Author Profile Icon Emil Atanasov
Emil Atanasov
Arrow right icon
View More author details
Toc

Table view in iOS app

First, let's create a new single view Xcode project with the default language Swift and target OS—iOS. We already know how to do this from previous chapters:

Open the storyboard and add a new table view controller. (Use the Utilities panel and the object library. If you filter the controls, you will find the Table View Controller in no time.) You should see two view controllers on the screen:

Two view controllers on the screen
Use a different scale level so that you can see more scenes at once.

Drag the gray/blue arrow (the one on the left) from the default view controller to the new view controller. This arrow defines which scene (screen) is the app's initial view controller. You can remove the other view controller, which we won't use.

Before defining the table cells, which should be used to render each item in the table, we need...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image