Create a Form in SwiftUI 2.0
By: Kuku Fuku
Tags: Swift, Mobile, Swiftui, iOS, Programming

Let’s Create a New Project!

Open Xcode > create a new project > Select SwiftUI interface and call it Form:

Screenshot from Xcode

Now open the ContentView.Swift file and add the following code above the body variable but under the struct :

http://hnue.edu.vn/dwu/Videos-Kaga-v-Electronic-Cup-cast01.html

http://hnue.edu.vn/dwu/Videos-Kaga-v-Electronic-Cup-cast02.html

http://hnue.edu.vn/dwu/Videos-Kaga-v-Electronic-Cup-cast03.html

http://hnue.edu.vn/dwu/Videos-Kaga-v-Electronic-Cup-cast04.html

http://hnue.edu.vn/dwu/Videos-Kaga-v-Electronic-Cup-cast05.html

http://hnue.edu.vn/dwu/video-US-v-Open-v-golf-tvjp1.html

http://hnue.edu.vn/dwu/video-US-v-Open-v-golf-tvjp2.html

http://hnue.edu.vn/dwu/video-US-v-Open-v-golf-tvjp3.html

http://hnue.edu.vn/dwu/video-US-v-Open-v-golf-tvjp4.html

http://hnue.edu.vn/dwu/video-US-v-Open-v-golf-tvjp5.html

http://hnue.edu.vn/dwu/HQ-videos-US-v-Open-v-golf-tv1.html

http://hnue.edu.vn/dwu/HQ-videos-US-v-Open-v-golf-tv2.html

http://hnue.edu.vn/dwu/HQ-videos-US-v-Open-v-golf-tv3.html

http://hnue.edu.vn/dwu/HQ-videos-US-v-Open-v-golf-tv4.html

http://hnue.edu.vn/dwu/HQ-videos-US-v-Open-v-golf-tv5.html

http://hnue.edu.vn/dwu/videos-US-Women-v-Open01.html

http://hnue.edu.vn/dwu/videos-US-Women-v-Open02.html

http://hnue.edu.vn/dwu/videos-US-Women-v-Open03.html

http://hnue.edu.vn/dwu/videos-US-Women-v-Open04.html

http://hnue.edu.vn/dwu/videos-US-Women-v-Open05.html

http://hnue.edu.vn/dwu/United-v-Women-v-Ope01.html

http://hnue.edu.vn/dwu/United-v-Women-v-Ope02.html

http://hnue.edu.vn/dwu/United-v-Women-v-Ope03.html

http://hnue.edu.vn/dwu/United-v-Women-v-Ope04.html

http://hnue.edu.vn/dwu/United-v-Women-v-Ope05.html

http://hnue.edu.vn/dwu/Videos-v-Gyastics-Jpan-Chamship01.html

http://hnue.edu.vn/dwu/Videos-v-Gyastics-Jpan-Chamship02.html

http://hnue.edu.vn/dwu/Videos-v-Gyastics-Jpan-Chamship03.html

http://hnue.edu.vn/dwu/Videos-v-Gyastics-Jpan-Chamship04.html

http://hnue.edu.vn/dwu/Videos-v-Gyastics-Jpan-Chamship05.html

https://ckscrapbookevents.com/vbm/Stn-v-Ben-soprza-tv-01.html

https://ckscrapbookevents.com/vbm/Stn-v-Ben-soprza-tv-02.html

https://ckscrapbookevents.com/vbm/Stn-v-Ben-soprza-tv-03.html

https://ckscrapbookevents.com/vbm/Stn-v-Ben-soprza-tv-04.html

https://ckscrapbookevents.com/vbm/Stn-v-Ben-soprza-tv-05.html

https://ckscrapbookevents.com/vbm/Bys-v-Clz--kijk-be-01.html

https://ckscrapbookevents.com/vbm/Bys-v-Clz--kijk-be-02.html

https://ckscrapbookevents.com/vbm/Bys-v-Clz--kijk-be-03.html

https://ckscrapbookevents.com/vbm/Bys-v-Clz--kijk-be-04.html

https://ckscrapbookevents.com/vbm/Bys-v-Clz--kijk-be-05.html

https://ckscrapbookevents.com/vbm/Rom-v-Sof-sky8-it-01.html

https://ckscrapbookevents.com/vbm/Rom-v-Sof-sky8-it-02.html

https://ckscrapbookevents.com/vbm/Rom-v-Sof-sky8-it-03.html

https://ckscrapbookevents.com/vbm/Rom-v-Sof-sky8-it-04.html

https://ckscrapbookevents.com/vbm/Rom-v-Sof-sky8-it-05.html

https://ckscrapbookevents.com/vbm/Nap-v-Soc-inizio-tv-01.html

https://ckscrapbookevents.com/vbm/Nap-v-Soc-inizio-tv-02.html

https://ckscrapbookevents.com/vbm/Nap-v-Soc-inizio-tv-03.html

https://ckscrapbookevents.com/vbm/Nap-v-Soc-inizio-tv-04.html

https://ckscrapbookevents.com/vbm/Nap-v-Soc-inizio-tv-05.html

https://ckscrapbookevents.com/vbm/v-ideo-Nice-lequipe-fr-01.html

https://ckscrapbookevents.com/vbm/v-ideo-Nice-lequipe-fr-02.html

https://ckscrapbookevents.com/vbm/v-ideo-Nice-lequipe-fr-03.html

https://ckscrapbookevents.com/vbm/v-ideo-Nice-lequipe-fr-04.html

https://ckscrapbookevents.com/vbm/v-ideo-Nice-lequipe-fr-05.html

https://ckscrapbookevents.com/vbm/Psv-v-Omn-gids-tv-01.html

https://ckscrapbookevents.com/vbm/Psv-v-Omn-gids-tv-02.html

https://ckscrapbookevents.com/vbm/Psv-v-Omn-gids-tv-03.html

https://ckscrapbookevents.com/vbm/Psv-v-Omn-gids-tv-04.html

https://ckscrapbookevents.com/vbm/Psv-v-Omn-gids-tv-05.html

https://simxperience.com/nuf1/Stn-v-Ben-soprza-tv-01.html

https://simxperience.com/nuf1/Stn-v-Ben-soprza-tv-02.html

https://simxperience.com/nuf1/Stn-v-Ben-soprza-tv-03.html

https://simxperience.com/nuf1/Stn-v-Ben-soprza-tv-04.html

https://simxperience.com/nuf1/Stn-v-Ben-soprza-tv-05.html

https://simxperience.com/nuf1/Bys-v-Clz--kijk-be-01.html

https://simxperience.com/nuf1/Bys-v-Clz--kijk-be-02.html

https://simxperience.com/nuf1/Bys-v-Clz--kijk-be-03.html

https://simxperience.com/nuf1/Bys-v-Clz--kijk-be-04.html

https://simxperience.com/nuf1/Bys-v-Clz--kijk-be-05.html

https://simxperience.com/nuf1/Rom-v-Sof-sky8-it-01.html

https://simxperience.com/nuf1/Rom-v-Sof-sky8-it-02.html

https://simxperience.com/nuf1/Rom-v-Sof-sky8-it-03.html

https://simxperience.com/nuf1/Rom-v-Sof-sky8-it-04.html

https://simxperience.com/nuf1/Rom-v-Sof-sky8-it-05.html

https://simxperience.com/nuf1/Nap-v-Soc-inizio-tv-01.html

https://simxperience.com/nuf1/Nap-v-Soc-inizio-tv-02.html

https://simxperience.com/nuf1/Nap-v-Soc-inizio-tv-03.html

https://simxperience.com/nuf1/Nap-v-Soc-inizio-tv-04.html

https://simxperience.com/nuf1/Nap-v-Soc-inizio-tv-05.html

https://simxperience.com/nuf1/v-ideo-Nice-lequipe-fr-01.html

https://simxperience.com/nuf1/v-ideo-Nice-lequipe-fr-02.html

https://simxperience.com/nuf1/v-ideo-Nice-lequipe-fr-03.html

https://simxperience.com/nuf1/v-ideo-Nice-lequipe-fr-04.html

https://simxperience.com/nuf1/v-ideo-Nice-lequipe-fr-05.html

https://simxperience.com/nuf1/Psv-v-Omn-gids-tv-01.html

https://simxperience.com/nuf1/Psv-v-Omn-gids-tv-02.html

https://simxperience.com/nuf1/Psv-v-Omn-gids-tv-03.html

https://simxperience.com/nuf1/Psv-v-Omn-gids-tv-04.html

https://simxperience.com/nuf1/Psv-v-Omn-gids-tv-05.html

http://trob.be/qbo/Stn-v-Ben-soprza-tv-01.html

http://trob.be/qbo/Stn-v-Ben-soprza-tv-02.html

http://trob.be/qbo/Stn-v-Ben-soprza-tv-03.html

http://trob.be/qbo/Stn-v-Ben-soprza-tv-04.html

http://trob.be/qbo/Stn-v-Ben-soprza-tv-05.html

http://trob.be/qbo/Bys-v-Clz--kijk-be-01.html

http://trob.be/qbo/Bys-v-Clz--kijk-be-02.html

http://trob.be/qbo/Bys-v-Clz--kijk-be-03.html

http://trob.be/qbo/Bys-v-Clz--kijk-be-04.html

http://trob.be/qbo/Bys-v-Clz--kijk-be-05.html

http://trob.be/qbo/Psv-v-Omn-gids-tv-01.html

http://trob.be/qbo/Psv-v-Omn-gids-tv-02.html

http://trob.be/qbo/Psv-v-Omn-gids-tv-03.html

http://trob.be/qbo/Psv-v-Omn-gids-tv-04.html

http://trob.be/qbo/Psv-v-Omn-gids-tv-05.html

http://www.daikimaru.jp/rux1/video-US-v-Open-v-golf-tvjp1.html

http://www.daikimaru.jp/rux1/video-US-v-Open-v-golf-tvjp2.html

http://www.daikimaru.jp/rux1/video-US-v-Open-v-golf-tvjp3.html

http://www.daikimaru.jp/rux1/video-US-v-Open-v-golf-tvjp4.html

http://www.daikimaru.jp/rux1/video-US-v-Open-v-golf-tvjp5.html

http://www.daikimaru.jp/rux1/HQ-videos-US-v-Open-v-golf-tv1.html

http://www.daikimaru.jp/rux1/HQ-videos-US-v-Open-v-golf-tv2.html

http://www.daikimaru.jp/rux1/HQ-videos-US-v-Open-v-golf-tv3.html

http://www.daikimaru.jp/rux1/HQ-videos-US-v-Open-v-golf-tv4.html

http://www.daikimaru.jp/rux1/HQ-videos-US-v-Open-v-golf-tv5.html

http://www.daikimaru.jp/rux1/videos-US-Women-v-Open01.html

http://www.daikimaru.jp/rux1/videos-US-Women-v-Open02.html

http://www.daikimaru.jp/rux1/videos-US-Women-v-Open03.html

http://www.daikimaru.jp/rux1/videos-US-Women-v-Open04.html

http://www.daikimaru.jp/rux1/videos-US-Women-v-Open05.html

http://www.daikimaru.jp/rux1/United-v-Women-v-Ope01.html

http://www.daikimaru.jp/rux1/United-v-Women-v-Ope02.html

http://www.daikimaru.jp/rux1/United-v-Women-v-Ope03.html

http://www.daikimaru.jp/rux1/United-v-Women-v-Ope04.html

http://www.daikimaru.jp/rux1/United-v-Women-v-Ope05.html

http://www.daikimaru.jp/rux1/Videos-Kaga-v-Electronic-Cup-cast01.html

http://www.daikimaru.jp/rux1/Videos-Kaga-v-Electronic-Cup-cast02.html

http://www.daikimaru.jp/rux1/Videos-Kaga-v-Electronic-Cup-cast03.html

http://www.daikimaru.jp/rux1/Videos-Kaga-v-Electronic-Cup-cast04.html

http://www.daikimaru.jp/rux1/Videos-Kaga-v-Electronic-Cup-cast05.html

https://eurekapartytents.com/xrw/roma-v-cska-it01.html

https://eurekapartytents.com/xrw/roma-v-cska-it02.html

https://eurekapartytents.com/xrw/roma-v-cska-it03.html

https://eurekapartytents.com/xrw/roma-v-cska-it04.html

https://eurekapartytents.com/xrw/roma-v-cska-it05.html

https://eurekapartytents.com/xrw/Arsenal-v-Dndalk-Euro01.html

https://eurekapartytents.com/xrw/Arsenal-v-Dndalk-Euro02.html

https://eurekapartytents.com/xrw/Arsenal-v-Dndalk-Euro03.html

https://eurekapartytents.com/xrw/Arsenal-v-Dndalk-Euro04.html

https://eurekapartytents.com/xrw/Arsenal-v-Dndalk-Euro05.html

https://eurekapartytents.com/xrw/Video-Nice-v-H-Beer01.html

https://eurekapartytents.com/xrw/Video-Nice-v-H-Beer02.html

https://eurekapartytents.com/xrw/Video-Nice-v-H-Beer03.html

https://eurekapartytents.com/xrw/Video-Nice-v-H-Beer04.html

https://eurekapartytents.com/xrw/Video-Nice-v-H-Beer05.html

https://eurekapartytents.com/xrw/videos-Lech-Rangers-v-en-gb-cks001.html

https://eurekapartytents.com/xrw/videos-Lech-Rangers-v-en-gb-cks002.html

https://eurekapartytents.com/xrw/videos-Lech-Rangers-v-en-gb-cks003.html

https://eurekapartytents.com/xrw/videos-Lech-Rangers-v-en-gb-cks004.html

https://eurekapartytents.com/xrw/videos-Lech-Rangers-v-en-gb-cks005.html

https://eurekapartytents.com/xrw/videos-napoli-v-sociedad-diretta-ing-it-it-1.html

https://eurekapartytents.com/xrw/videos-napoli-v-sociedad-diretta-ing-it-it-2.html

https://eurekapartytents.com/xrw/videos-napoli-v-sociedad-diretta-ing-it-it-3.html

https://eurekapartytents.com/xrw/videos-napoli-v-sociedad-diretta-ing-it-it-4.html

https://eurekapartytents.com/xrw/videos-napoli-v-sociedad-diretta-ing-it-it-5.html

https://ckscrapbookevents.com/nxu/roma-v-cska-it01.html

https://ckscrapbookevents.com/nxu/roma-v-cska-it02.html

https://ckscrapbookevents.com/nxu/roma-v-cska-it03.html

https://ckscrapbookevents.com/nxu/roma-v-cska-it04.html

https://ckscrapbookevents.com/nxu/roma-v-cska-it05.html

https://ckscrapbookevents.com/nxu/Arsenal-v-Dndalk-Euro01.html

https://ckscrapbookevents.com/nxu/Arsenal-v-Dndalk-Euro02.html

https://ckscrapbookevents.com/nxu/Arsenal-v-Dndalk-Euro03.html

https://ckscrapbookevents.com/nxu/Arsenal-v-Dndalk-Euro04.html

https://ckscrapbookevents.com/nxu/Arsenal-v-Dndalk-Euro05.html

https://ckscrapbookevents.com/nxu/Video-Nice-v-H-Beer01.html

https://ckscrapbookevents.com/nxu/Video-Nice-v-H-Beer02.html

https://ckscrapbookevents.com/nxu/Video-Nice-v-H-Beer03.html

https://ckscrapbookevents.com/nxu/Video-Nice-v-H-Beer04.html

https://ckscrapbookevents.com/nxu/Video-Nice-v-H-Beer05.html

https://ckscrapbookevents.com/nxu/videos-Lech-Rangers-v-en-gb-cks001.html

https://ckscrapbookevents.com/nxu/videos-Lech-Rangers-v-en-gb-cks002.html

https://ckscrapbookevents.com/nxu/videos-Lech-Rangers-v-en-gb-cks003.html

https://ckscrapbookevents.com/nxu/videos-Lech-Rangers-v-en-gb-cks004.html

https://ckscrapbookevents.com/nxu/videos-Lech-Rangers-v-en-gb-cks005.html

https://ckscrapbookevents.com/nxu/videos-napoli-v-sociedad-diretta-ing-it-it-1.html

https://ckscrapbookevents.com/nxu/videos-napoli-v-sociedad-diretta-ing-it-it-2.html

https://ckscrapbookevents.com/nxu/videos-napoli-v-sociedad-diretta-ing-it-it-3.html

https://ckscrapbookevents.com/nxu/videos-napoli-v-sociedad-diretta-ing-it-it-4.html

https://ckscrapbookevents.com/nxu/videos-napoli-v-sociedad-diretta-ing-it-it-5.html

https://www.rcc.org.uk/vmex/videos-Lech-Rangers-v-en-gb-cks001.html

https://www.rcc.org.uk/vmex/videos-Lech-Rangers-v-en-gb-cks002.html

https://www.rcc.org.uk/vmex/videos-Lech-Rangers-v-en-gb-cks003.html

https://www.rcc.org.uk/vmex/videos-Lech-Rangers-v-en-gb-cks004.html

https://www.rcc.org.uk/vmex/videos-Lech-Rangers-v-en-gb-cks005.html

https://www.rcc.org.uk/vmex/Arsenal-v-Dndalk-Euro01.html

https://www.rcc.org.uk/vmex/Arsenal-v-Dndalk-Euro02.html

https://www.rcc.org.uk/vmex/Arsenal-v-Dndalk-Euro03.html

https://www.rcc.org.uk/vmex/Arsenal-v-Dndalk-Euro04.html

https://www.rcc.org.uk/vmex/Arsenal-v-Dndalk-Euro05.html

We are going to use these different states in our textfield and picker to modify the value.

Also, replace the current body variable with the following: