Hello, this will be my first technical blog post. I spent a while googling how to do this, and for the life of me I could not find a tutorial in Swift on how to do this. However, I did find this tutorial which I recommend reading: https://www.raywenderlich.com/336/auto-complete-tutorial-for-ios-how-to-auto-complete-with-custom-values
What this tutorial will cover will be how to type into a UITextField and have a list of possible results which YOU supply show up. I personally like it when tutorials show you the end result first so you know what your product will look like before you read too far into it; that being said here is the final result.
Glamorous I know. You will find other tutorials on how to make this prettier I'm sure, but as far as basic functionality goes this app works how it should.
I will show more pictures than you probably need, but I feel it's better safe than sorry.
First create a new project.
First we are going to drag a UITextField onto the story board. Either find this by scrolling down or start typing it in. Now drag the text field onto the screen. It doesn't matter where you place it as we will be telling xCode exactly where to put it.
Once you have placed the textfield tap the button seen in the next image. This will help you align the textfield to the storyboard.
Tap the check mark next to what i have done. This will align the horizontal center of the textfield to the center of the storyboard horizontally no matter what phone type or orientation.
Next tap the Tie Fighter looking icon right next to what we just clicked (please know that reference). If you don't see the next photo.
At the top of the dialog box is a 4 way (top, left, right, bottom) interactive field. First tap the top line and it will change to solid red. Type in 175. Now tap the Width and Height checkmarks and change the value to 150 for the width and 40 for the height. DON'T continue any further yet as there is one more thing you must do!!!!
You should be looking like this right now.
Going back to our storyboard add a tableview cell INSIDE the tableview