Reputation: 311
how to use UISegmentedControl to change datasource in tableview? with sql tables or read data from arrays thanks
Upvotes: 2
Views: 1008
Reputation: 523274
-addTarget:action:forControlEvents:
(with events UIControlEventValueChanged) to set up a response action for the segmented control.selectedSegmentIndex
property. Use this to determine which data source to use.dataSource
property.Upvotes: 3