Iphone开发笔记--Custom UITableVIewCell

    技术2022-05-19  22

    Custom UITableVIew有时会遇到EXC_BAD_ACCESS

     

    可能原因

     

    1、调用同类型xib所致

    在TeamInfoVC类中调用

    NSArray *topLevelObjects = [[NSBundle mainBundle] loadNibNamed:@"teamInfoVC" owner:self options:nil];

    // Grab a pointer to the first object (presumably the custom cell, as that's all the XIB should contain).

    ImageCell* cell = [topLevelObjects objectAtIndex:0];

     

    所以在同个xib下,只能调用一次。或者从其他xib中建立custom tableviecell


    最新回复(0)