Non-alphabetical index for UITableView

How to implement NON alphabetical index for UITableView? An example of this can be seen in the Apple Remote app. When viewing songs on the right side there is a dotted pointer that allows the user to quickly scroll through the entire table. There are also no section headers.

thank

+3
source share
2 answers

I would suggest that it works by returning an array full of midpoint character (Unicode 00B7), reserved by the bullet character (2022). In a remote application, the index contains 23 elements; therefore, for this you need to divide your data into 23 sections of approximately equal length. As the occult, return nilor @""to -tableView:titleForHeaderInSection:not lead to the display section headers.

Return the aforementioned array of characters to the data source method -sectionIndexTitlesForTableView:, then execute -tableView:sectionForSectionIndexTitle:atIndex:to return the index of the section that it gives you, and you should get the same behavior as in Remotes.

+2
source

@"" , , . ( ), , , , , .

, . UITableViewDelegate:

- (NSArray *)sectionIndexTitlesForTableView:(UITableView *)tableView
+1

All Articles