Home > DeveloperSection > Forums > How to set text in table cell to Right and Left in iOS
Pooja Malohtra
Pooja Malohtra

Total Post:47

Points:331
Posted on    November-17-2015 4:39 AM

 iPhone iPhone  Ios  Objective C 
Ratings:


 1 Reply(s)
 292  View(s)
Rate this:
I have created an app using table view, now I have a problem,
I am not understanding how to display text in both alignment right and left into table cell.
can any one tell me, how to do it?


Tarun Kumar

Total Post:213

Points:1635
Supported
Posted on    November-17-2015 11:19 PM

I think you are not using appropriate table cell style,
your table cell style is set by default this: UITableViewCellStyleDefault
replace it with this: UITableViewCellStyleSubtitle in your code:
Example:

UITableViewCell *cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle
                                                 resuseIdentifier:CellIdentifer] autorelease];

 


Don't want to miss updates? Please click the below button!

Follow MindStick