Settings view with user text input - ios

I'm new to iOS development and trying to figure out how these in-app settings views are done where you can change your contact details and a few other settings.
My first attempt was a static table but I couldn't figure out how to override the cell content with a text input field. Is this the way to go? If yes, what's the easiest way to add a text input field to the cell that I can preset with the user data (coming from our server)?

For a static TVC, set the cell type to custom and you can drag out labels and fields as you need.

Related

How to design a add new entry screen like in the Health app?

I'm creating my first app and I wanted to design an "add a new item" modal like in the health app:
Here I have three questions:
How the 3 input fields are designed that you see the hint all the time on the left and the imput on the right? Is this just one field?
Are this 3 fields usually stored in a tableView?
Is the entry for the Date a special keyboard type or a DatePicker?
That looks like a UITableView with a custom cell which has a UILabel on the left and an input field on the right. The picker is a UIDatePicker

iOS UI: How to make the control that is used in alarm app?

I want to create several controls just like the ones below the date time picker in the alarm app. They look like label controls, but they have a title on the left, the currently selected data value on the right, and an arrow all the way to the right. The Snooze control does not have an arrow, but I believe it is the same control. What type of control would I use to do this?
Any samples out there for this in Swift?
Thanks in advance.
It sounds like you are talking about different styles of cells of a table view.
The first control you mentioned (label on left, selected data value on right) is simply a table view cell with the RightDetail style and Disclosure Indicator accessory view.
The control with the switch is not a default cell style so you will have to make your own custom Table View cell. There are plenty of tutorials online that show how to make your own style of Table View cells. The item on the right is just a regular Switch.

Swift ios8: How to make single row picker with option for manual text entry?

I would like to give my iPhone App user the option of whether to use a picker (i.e., scroll wheel) or keyboard to input the value of a field. I'd like it to where the current value of the field effectively displays as isolated text (i.e., as a label, with the picker and keyboard hidden). But the user can change the field's value by either (A) performing a single tap on the label to reveal the keyboard so the user can type in a different value; or (B) perform a swipe on the label to reveal the picker so the user can user the picker to change the value. This will present a very clean interface in my opinion, without the clutter of the keyboard, text field, or picker unless the user changes the value. Help?
This control doesn't exist, but a possible solution would be to add a cell under the UIPickerView (assuming your using a table form) when the "Custom" option is selected and add a text field to that cell allowing custom input. Make sure you hide the cell if the UIPickerView value changes from "Custom" to avoid user confusion.

How do i make a picker show up when a user selects a text field

I am new to swift and have trouble making drop down lists.
I have a story board that needs to contain about 6 questions the user needs to fill in and so far all i have working is picker views and i can only fit 2 or 3 on the screen.
What is the best way to to create a drop down lists in Swift?
For implementing drop down you can use the table view,set its hidden property YES and when user clicks on the text field change hidden property to NO.This is the easiest way to implement drop down using table view in ios.

Dynamic editable form with UITableView and storyboard

I'm trying to create a edit user information page for the user that is using my app, which their editable info would include something like: name, surname, phone numbers, emails, etc.
So I want to create a form using a UITableView with prototype cell in storyboard for each type of data, but here's the catch: There can be a variable amount of each type e.g. user can add or delete emails. Each cell might have a text field for the user to modify their data.
My question is, how do I retrieve the information entered into each cell? Because their can be a variable amount of each cell, I cannot statically tie each field to a property in my class.
You can make custom cells according to the type of cell. So whenever user want to add any field then they can select from your predefined type of cells. It will be easy for you to retrieve data according to their type and they also can multiple field of same category or other category..
You can give option to add a custom cell in which label and textfield will be.. then label text can be retrieved as category and textfield can be retrieved as value for that category. To recognize the type of category you can mention the category in a picker. And write the code for the validation of that type of cell. And if their id other category jus put its type as string. Likewise you can retrieve both value and type.

Resources