Welcome, Guest
Username Password: Remember me

Custom Cell Labels in Sectioned TableView
(1 viewing) (1) Guest
  • Page:
  • 1

TOPIC: Custom Cell Labels in Sectioned TableView

Custom Cell Labels in Sectioned TableView 1 year, 6 months ago #1

Can you please send me the sample trial code that worked perfectly.

I just spent an hour creating the simplest possible sectioned table view with custom labels and it still does not work. I get wrong/repeating labels from random sections.

Please send sample code.
  • baberuth22
  • OFFLINE
  • Expert Boarder
  • Posts: 84
  • Karma: 2

Re: Custom Cell Labels in Sectioned TableView 1 year, 6 months ago #2

"We find this comment extremely absurd and offending to everyone who have worked in testing this out.

FYI, your *own* untouched code works *perfectly* in our test environment, as per the following video:



If you give us permission, we could also post your sample project to this post for others to test too."



--------------------------------------------------


1. If you built a project that works perfectly, why are you using the example I sent you?

Where is your sample code? I often get the response from you guys "just do this" with no example, and 90% of the time it does not work that way.

Again, where is your sample code?


2. THE VIDEO YOU POSTED DEMONSTRATES IT NOT WORKING!!!!! The labels in the middle should be identical to the labels on the left (counting up to 100), but they are clearly rearranged with 1-9 occurring often and random values mixed in.

Please look at your sample and test before posting next time.

I am offended that you would post such OBVIOUSLY buggy code and say it works "perfectly". Hello??
  • baberuth22
  • OFFLINE
  • Expert Boarder
  • Posts: 84
  • Karma: 2
Last Edit: 1 year, 6 months ago by baberuth22.

Re: Custom Cell Labels in Sectioned TableView 1 year, 6 months ago #3

I just read you are going to close the topic and have no solution.

Why? Can you get this to work?
  • baberuth22
  • OFFLINE
  • Expert Boarder
  • Posts: 84
  • Karma: 2

Re: Custom Cell Labels in Sectioned TableView 1 year, 6 months ago #4

Setting the label outside the if else block worked. Thanks Tarek.




UILabel *castLabel = nil;
for(UIView *subview in cell.subviews)
if(subview.tag == 100)
{
castLabel = (UILabel *)subview;
break;
}

if(!castLabel)
{
castLabel = [UILabel alloc] init];
castLabel.tag = 100;
//castLabel.text = @"my text";
[cell addSubview:castLabel];
[castLabel release];
}

castLabel.text = @"my text";
  • baberuth22
  • OFFLINE
  • Expert Boarder
  • Posts: 84
  • Karma: 2
  • Page:
  • 1
Time to create page: 0.87 seconds