1、自定义索引
准备数据,设计一个数组,数组里面的元素为每个section的数组。
//返回Section总数
-(NSInteger)numberOfSectionsInTableV
{
}
//返回每个Section的行数
-(NSInteger)tableView:(UITableView *)tableViewnumberOfRowsInSection:(NSInteger)section
{
}
//返回每个Section的title
-(NSString*)tableView:(UITableView*)tableView titleForHeaderInSection:(NSInteger)section
{
}
//返回索引栏数据
-(NSArray*)sectionIndexTitlesForTab
{
}
//建立索引栏和section的关联
-(NSInteger)tableView:(UITableView *)tableViewsectionForSectionIndexTi
{
}
-(NSInteger)numberOfSectionsInTableV
}
//返回每个Section的title
-(NSString*)tableView:(UITableView*)tableView titleForHeaderInSection:(NSInteger)section
{
}
//返回索引栏的列别数据
-(NSArray*)sectionIndexTitlesForTab
}
//建立关联
-(NSInteger)tableView:(UITableView *)tableViewsectionForSectionIndexTi
}
//每个Section的行数
-(NSInteger)tableView:(UITableView *)tableViewnumberOfRowsInSection:(NSInteger)section {
}