views:

1199

answers:

1

Using the following code I am getting the text.label but not the detailTextLabel.text. The NSLog is displaying correctly.

cell.textLabel.text = [eventLabels objectAtIndex:indexPath.row];  
cell.detailTextLabel.text = [eventFields objectAtIndex:indexPath.row]];  

NSLog(@"%@", [eventFields objectAtIndex:indexPath.row]);  

I also tried...

cell.detailTextLabel.text = [NSString stringWithFormat:@"%@", [eventFields objectAtIndex:indexPath.row]];     

I have not had problems with this before. Any suggestions?

John

+4  A: 

Make sure you're using an appropriate UITableViewCellStyle with this (anything but UITableViewCellStyleDefault should thus work). The cell's style is specified when you initialize it.

jbrennan
That was it!!!! I was using but UITableViewCellStyleDefault. I think I used what was provided when I created the class without thinking about. Thanks so much.John