Add this to your viewDidLoad:
to remove the table borders:
self.tableView.separatorStyle = UITableViewCellSeparatorStyleNone;
I didn't understood your problem quite well,but i recommend you to check the height of your cell background view,just as a test put an image as the cell background view and check if the white line stills there:
cell.backgroundView = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"imageName.png"]]autorelease];
//-----
The code you provide isn't working because you're creating a new blank UIView and setting it as the cell background!The correct method follows:
-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{
static NSString *CellIdentifier = @"ApplicationCell";
UITableViewCell *cell = (UITableViewCell *)[self.tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];
UIView *myBackgroundView = [[UIView alloc] init];
myBackgroundView.frame = cell.frame;
myBackgroundView.backgroundColor = [UIColor greenColor]; <== DESIRED COLOR
cell.backgroundView = myBackgroundView;
}
return cell;
}