racharambola
racharambola

Reputation: 417

Problem with empty sections in UITableView

I am trying to display the data on the UITableIndexed View and I deleted the empty sections in the table.Now the problem is I added a gradient image as the background to the UITableView, it displays fine for all the cells, but when there is an empty section it displays a row with white color with which the appearance of the table view is not appealing. How I can permanently delete the empty sections from the table??

Also can anyone please tell me how to display only the indexes which have the sections.

I will be waiting for your reply. I am a newbie in iphone programming, I think it might sound silly to ask but I want to learn from the advices from you.

Upvotes: 1

Views: 582

Answers (2)

RVN
RVN

Reputation: 4187

For the empty cell

  1. Set the background of the TableView to clearColor

  2. Set the separator color to clear color

This will do

Upvotes: 1

fogelbaby
fogelbaby

Reputation: 311

Also can anyone please tell me how to display only the indexes which have the sections.

When you produce the array that will be shown as the indexes, you need to go through your sections and only put the ones that have data on that array. There's no automatic way to do it.

Upvotes: 0

Related Questions