swift - load a different view controller or tableview depending on previous button pressed -
i new swift coding. being said, i'm looking transition "home page" tableview or new view controller once menu item has been selected. curious how go using 1 view controller/tableview loading contents inherited file based on selection made previous.
example: home - chores @ home - chores @ work - chores @ school
a selection of chores @ home selected, 1 segue prepared loads view controller downstream in xcode, loads content differently if had selected chores @ work. hope makes sense , thank in advance. if not mistaken, considered subclasses uiviewcontroller or uitableview???
you may needs see uitableview docs, can set different datasource depends on selection apple link docs https://developer.apple.com/library/ios/documentation/uikit/reference/uitableview_class/
and here simple tutorial follow
http://www.codingexplorer.com/getting-started-uitableview-swift/
Comments
Post a Comment