• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: How to change UITableView cell style dynamically
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to change UITableView cell style dynamically


  • Subject: Re: How to change UITableView cell style dynamically
  • From: Tharindu Madushanka <email@hidden>
  • Date: Sat, 21 Nov 2009 20:08:54 +0530

mm ok I will add two types of cells. But since its only a single cell table,
I thought there would not be any performance issue or something doing that.

On Sat, Nov 21, 2009 at 8:01 PM, Luke Hiesterman <email@hidden> wrote:

> If you have 2 different styles of cells then you should have 2 different
> reuse identifiers. Then when you dequeue, you ask for an available cell of
> the apropeiate type.
>
> Luke
>
> Sent from my iPhone.
>
>
> On Nov 21, 2009, at 1:55 AM, Tharindu Madushanka <email@hidden>
> wrote:
>
>  Hi
>>
>> Removing reuse identifier solved the problem so now I am creating a cell
>> like below. It worked.
>>
>> UITableViewCellStyle style;
>> if(profile.name.length > 0) {
>>   style = UITableViewCellStyleSubview;
>> } else {
>>   style = UITableViewCellStyleDefault;
>> }
>>
>> UITableViewCell *cell = [[[UITableViewCell alloc] initWithStyle:style
>> reuseIdentifier:nil]autorelease];
>>
>> No reuse identifiers or dequeue method in table view is not used while
>> creating cells
>>
>> Since its only once cell, doing this is ok ? is it ?
>>
>> -Tharindu
>> _______________________________________________
>>
>> Cocoa-dev mailing list (email@hidden)
>>
>> Please do not post admin requests or moderator comments to the list.
>> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>>
>> Help/Unsubscribe/Update your Subscription:
>>
>> This email sent to email@hidden
>>
>
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: How to change UITableView cell style dynamically
      • From: Luke Hiesterman <email@hidden>
References: 
 >How to change UITableView cell style dynamically (From: Tharindu Madushanka <email@hidden>)
 >Re: How to change UITableView cell style dynamically (From: Tharindu Madushanka <email@hidden>)
 >Re: How to change UITableView cell style dynamically (From: Luke Hiesterman <email@hidden>)

  • Prev by Date: Saving data as NSData using NSUserDefaults
  • Next by Date: Re: Saving data as NSData using NSUserDefaults
  • Previous by thread: Re: How to change UITableView cell style dynamically
  • Next by thread: Re: How to change UITableView cell style dynamically
  • Index(es):
    • Date
    • Thread