func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell
{
let cellFrame = CGRectMake(0, 0, tableView.frame.width, 100)
var retCell = UITableViewCell(frame: cellFrame)
var textView = UITextView(frame: CGRectMake(8,30,tableView.frame.width-8-8,65))
textView.layer.borderColor = UIColor.blueColor().CGColor
textView.layer.borderWidth = 1
retCell.addSubview(textView)
if(reqGrpIndex == 0){
reqGrpIndex = reqGrpIndex + 1
}
}
Why shouldn't we add subview on this function?? How can change the code to be a good practice for doing same purpose?