ios - Unique UITableViewCell with different functionality -


Each of my projects UITableViewCell need to show as a unique I say 10 cells, all 10 cells There will be various subwigs attached to it. To achieve this goal, I am creating new cells every time which means that I am not dequeCell: . Every time I have been assigned a new cell

  - (UITableViewCell *) Talikadrishy: (UITableView *) Table View Selforroattindappath: (Ansaisakspath *) Suckankpth {UITableViewCell * cell = no sales = [[ UITableViewCell alloc] initWithStyle: UITableViewCellStyleDefault reuseIdentifier: @ "ABC"]; Return cell; }  

Whether it is okay to proceed with this or there is a better alternative approach.

and which is required to download images from a cell URL I use the following would slice

  [imgSection setImage: [UIImage imageWithData: [NSData dataWithContentsOfURL: [NSURL URLWithString: column.icon]]]];  

Please help me with the solution

you do this can make reuse identifier

  - (UITableViewCell *) tableView: (UITableView *) tableView cellForRowAtIndexPath: (NSIndexPath *) indexPath {NSString * _cellIdentifier = [NSString stringWithFormat: @ "RowIdent % Ld ", (long) indexPath.row]; Table viewer * _cell = [Tableview decouple reusable light identifier: _cellIdentifier]; If (! _cell) {_cell = [[Table view CL alloc] initWithStyle: UITableViewCellStyleDefault reuseIdentifier: _cellIdentifier]; } // awesome return _cell; }  

You can depend on the cell identifier line number. In this case the reuse identifier will work properly, but all your cells will be unique

Update:

Try to use to download the image UIImageView + AFNetworking.h with>

  - setImageWithURLRequest (zero): (NSURLRequest *) URLRequest placeholderImage: (UIImage *) placeholderImage success: (void (^) (NSURLRequest * request, NSHTTPURLResponse * reaction, UIImage * image)) success or failure: (void (^) (NSURLRequest * request, NSHTTPURL Uttrpreshn * feedback , NSError * error)) failure;  

method ().

Hope it helps.


Comments

Popular posts from this blog

sqlite3 - UPDATE a table from the SELECT of another one -

c# - Showing a SelectedItem's Property -

javascript - Render HTML after each iteration in loop -