ios - How to get UITableView Label Text string - Custom Cell -
i have uitableview customcell. custom cells contain uilabel , uiimageview.
i saw online possible text normal uitableview cell , store in string when user presses cell.
but how can when using custom cell? becuase name of uilabel "type_label" , has been defined in header file of customcell xib.
so in xcode can't use:
cell.type_label.text" in following function:
-(void)tableview:(uitableview *) tableview didselectrowatindexpath:(nsindexpath *)indexpath thanks, dan.
in tableviewdidselectrow need is:
uitableviewcellcustomclass *customcell = (uitableviewvellcustomclass*)[tableview cellforrowatindexpath:indexpath]; nsstring *labeltext = [[customcell type_label] text]; that should want need.
Comments
Post a Comment