How to add Sections, Headers, Footers to TableView in iOS (Swift 2020)

  Рет қаралды 33,946

iOS Academy

iOS Academy

Күн бұрын

Пікірлер: 59
@caminaydime
@caminaydime 3 жыл бұрын
After some days looking for the correct way to show the data, now I finally did it! Thank you for your simplicity, others videos they put a lot of things and loose the point of the tutorial that is TEACH, and the best way to teach is simplicity!
@iOSAcademy
@iOSAcademy 3 жыл бұрын
Glad it helped!
@vishwajeetpatil9381
@vishwajeetpatil9381 3 жыл бұрын
heightForHeaderInSection is not working for me. My Xcode version is 13 What should I do ?
@antonioporeiro9270
@antonioporeiro9270 Жыл бұрын
After one year nobody dont tell what wrong(
@Nickarietta31
@Nickarietta31 Жыл бұрын
not working for me either. I'm also Xcode 13
@UjinKrabs
@UjinKrabs 8 ай бұрын
Not working for me either too! Xcode 13
@UjinKrabs
@UjinKrabs 8 ай бұрын
Maybe. func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? { return UIView.init(frame: CGRect.init(x: 0, y: 0, width: tableView.frame.width, height: 50)) }
@UjinKrabs
@UjinKrabs 7 ай бұрын
together with . func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat { return 100 } func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? { return UIView.init(frame: CGRect.init(x: 0, y: 0, width: tableView.frame.width, height: 50)) }
@sarathchandradamineni6656
@sarathchandradamineni6656 3 жыл бұрын
Very straight forward, abstract and clear information. thank you and really helpful
@iOSAcademy
@iOSAcademy 3 жыл бұрын
You’re welcome
@Nickarietta31
@Nickarietta31 Жыл бұрын
func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat { return 20.0 This isn't working for me. I'm using Xcode 13. Thoughts?
@Ikona731
@Ikona731 Жыл бұрын
Me either, did you find a solution?
@ActionCloud
@ActionCloud 4 жыл бұрын
favorite channel at the moment! Keep it up!
@iOSAcademy
@iOSAcademy 4 жыл бұрын
Thanks! Make sure to subscribe for more
@ActionCloud
@ActionCloud 4 жыл бұрын
iOS Academy already done!
@mak_whisk
@mak_whisk 2 жыл бұрын
Thank you
@iOSAcademy
@iOSAcademy 2 жыл бұрын
Youre welcome
@defyent
@defyent 4 жыл бұрын
would much rather look at the entire screen so we can see everything at once instead of all the zooming and mouse follow stuff, otherwise great video thank you.
@iOSAcademy
@iOSAcademy 4 жыл бұрын
Thanks for the feedback & thanks for watching!
@George-yk9xi
@George-yk9xi 4 жыл бұрын
Another awesome video as always, thanks a lot!!
@iOSAcademy
@iOSAcademy 4 жыл бұрын
You’re welcome, make sure to subscribe
@sovrinfo
@sovrinfo 2 жыл бұрын
Thanks you a lot!
@iOSAcademy
@iOSAcademy Жыл бұрын
Youre welcome
@Jonas-md7qg
@Jonas-md7qg 3 жыл бұрын
Hey I can't access the Arrays in the Array by referring to them as sections.. maybe you can help me with that? - Great Videos btw!! 🔥
@iOSAcademy
@iOSAcademy 3 жыл бұрын
What error do you get? I have a hunch your syntax is incorrect
@erickramones2167
@erickramones2167 4 жыл бұрын
you should record the entire screen like at 3:36
@iOSAcademy
@iOSAcademy 4 жыл бұрын
Thanks for the feedback
@tibettenballs4962
@tibettenballs4962 2 жыл бұрын
you should stop telling my man what to do.
@calebgates2307
@calebgates2307 Жыл бұрын
10:50 Please please please tell how to set an arbitrary height for the header, which will depend on the size of the label that is put inside of the view. Should it be done in viewDidLayoutSubviews? Is it the systemLayoutSizeFitting? Please help!
@GurpreetSingh-fb4pn
@GurpreetSingh-fb4pn 4 жыл бұрын
good explanation dude
@lansky2947
@lansky2947 4 жыл бұрын
Could you teach me how to make a footer isn't scrolling with the tableview? Thanks
@iOSAcademy
@iOSAcademy 4 жыл бұрын
Sure! Do you mean a "sticky" footer that does not scroll? Or a footer all the way at bottom of scroll area? Make sure to subscribe so you don't miss the video :)
@lansky2947
@lansky2947 4 жыл бұрын
@@iOSAcademyI mean sticky footer that doesn't scroll with tableview, because I want making a ads view on there. By the way your tutorial viedo is great. XD
@travelfeaturedyournexttrav5368
@travelfeaturedyournexttrav5368 4 жыл бұрын
good afternoon sorry but i have one problem with my code in my application. the question is i crate a tableview end i create the extension for convert in pdf end print it, but when i print it is come out like e column and not cover all page. can you help me? thank you so much
@arvinstark667
@arvinstark667 4 жыл бұрын
How can I make header or footer of the table view fixed?
@iOSAcademy
@iOSAcademy 4 жыл бұрын
Youd use an extra external view
@manikantanallabothu8788
@manikantanallabothu8788 3 жыл бұрын
How to give header and footer for evry section
@Ikona731
@Ikona731 Жыл бұрын
func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat { return 20 } is not working to space sections is there another way to do so?
@iOSAcademy
@iOSAcademy Жыл бұрын
Are you registering and dequeueing the header?
@UjinKrabs
@UjinKrabs 8 ай бұрын
@@iOSAcademy This working for me. Xcode 13. func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? { return UIView.init(frame: CGRect.init(x: 0, y: 0, width: tableView.frame.width, height: 50)) }
@UjinKrabs
@UjinKrabs 7 ай бұрын
@@iOSAcademy This works for me -> Xcode 13 func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat { return 100 } func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? { return UIView.init(frame: CGRect.init(x: 0, y: 0, width: tableView.frame.width, height: 50)) }
@UjinKrabs
@UjinKrabs 7 ай бұрын
Working. Xcode version is 13. func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? { return UIView.init(frame: CGRect.init(x: 0, y: 0, width: tableView.frame.width, height: 8)) } func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat { return 100 }
@hanzalaraza8709
@hanzalaraza8709 3 жыл бұрын
Hey , How can i manage pagination with section header is the date (which is dynamic in every pagination) and every date has some activity which has to be shown under the date section and so on
@jojuanf9988
@jojuanf9988 4 жыл бұрын
Awesome video man
@iOSAcademy
@iOSAcademy 4 жыл бұрын
Thanks! Make sure to subscribe for more :)
@xDARKandOMINOUSx
@xDARKandOMINOUSx 4 жыл бұрын
Am I missing something? Did a PRINT statement in the didSelectRowAt block and it isn't working?
@iOSAcademy
@iOSAcademy 4 жыл бұрын
Did you set the delegate to self?
@cem890
@cem890 4 жыл бұрын
How can we divide the data captured with json into sections?
@iOSAcademy
@iOSAcademy 4 жыл бұрын
You should use multi dimensional arrays
@TheBooban
@TheBooban 3 жыл бұрын
@@iOSAcademy What? Show us please. filter. reduce. oh my!
@abs_goose2712
@abs_goose2712 4 жыл бұрын
Is there a way to build out header and footer views in storyboards?
@iOSAcademy
@iOSAcademy 4 жыл бұрын
Yes! You can simply drag a uiview into the tableview
@cem890
@cem890 4 жыл бұрын
@@iOSAcademy how can make sticky header with this uiview
@danya4462
@danya4462 3 жыл бұрын
Спасибо. очень полезно
@rohitoznikam3735
@rohitoznikam3735 4 жыл бұрын
Too much zoom in and zoom out is irritating instead increase the font size please ?
@iOSAcademy
@iOSAcademy 4 жыл бұрын
Good feedback, newer videos have less zoom
@Iiliest
@Iiliest 4 жыл бұрын
Wow we get clickbated so hard. This dude literally said on iOS. But I guess he lied-
@iOSAcademy
@iOSAcademy 4 жыл бұрын
Sorry you feel that way. Please do share what topic i missed when covering this
@judedavis92
@judedavis92 3 жыл бұрын
This is on iOS, stupid!! So stupid
Button & Actions in TableView Cells in Swift 5 (Xcode 12 - 2023)
12:53
TableView With Custom Cells In Swift - Tutorial
16:40
iOS Academy
Рет қаралды 54 М.
Un coup venu de l’espace 😂😂😂
00:19
Nicocapone
Рет қаралды 12 МЛН
Seja Gentil com os Pequenos Animais 😿
00:20
Los Wagners
Рет қаралды 33 МЛН
龟兔赛跑:好可爱的小乌龟#short #angel #clown
01:00
Super Beauty team
Рет қаралды 56 МЛН
😜 #aminkavitaminka #aminokka #аминкавитаминка
00:14
Аминка Витаминка
Рет қаралды 1,7 МЛН
iOS swift Simple Tableview in Tamil
27:38
Technology Career Development Center 100% Job
Рет қаралды 1,2 М.
How to use Auto Layout for beginners in Swift - iOS 2023
13:49
iOS Academy
Рет қаралды 77 М.
How Fast Can I Fill My Inbox?
13:30
Dev Detour
Рет қаралды 352 М.
Expanding Table View Cells! (Swift 4 in Xcode)
13:01
Jared Davidson
Рет қаралды 122 М.
Diffable Data Source (Swift 5, Xcode 12, TableView) - iOS 2020
16:54
Malware Development: Processes, Threads, and Handles
31:29
Un coup venu de l’espace 😂😂😂
00:19
Nicocapone
Рет қаралды 12 МЛН