Hi,
I am using the following code snippet, which seems to work I think…./
// Get a handle to the photo's title and description
NSString *photoTitle = [photosInPlace objectForKey:TITLE_KEY];
NSString *photoDescription = [photosInPlace valueForKeyPath:DESCRIPTION_KEY];
// If the photo title is available set the cell's title to photoTitle and the cell's
// subtitle to the photo description
if (photoTitle && ![photoTitle isEqualToString:@""]) {
cell.textLabel.text = photoTitle;
cell.detailTextLabel.text = photoDescription;
// else if the photo description is available set the title equal to it
} else if (photoDescription && ![photoDescription isEqualToString:@""]) {
cell.textLabel.text = photoDescription;
cell.detailTextLabel.text = @"";
// else set the title to Unknown
} else {
cell.textLabel.text = @"Unknown";
cell.detailTextLabel.text = @"";
}
Are you using isEqualToString do to the comparison?
--
You received this message because you are subscribed to the Google Groups "iPhone Application Development Auditors" group.
To view this discussion on the web visit https://groups.google.com/d/msg/iphone-appdev-auditors/-/s7IL-_G4NdQJ.
To post to this group, send email to iphone-appd...@googlegroups.com.
To unsubscribe from this group, send email to iphone-appdev-aud...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/iphone-appdev-auditors?hl=en.