iOS Development Uitableviewcontroller

Source: Internet
Author: User

# RssListController.h

@interface Rsslistcontroller:uitableviewcontroller <MWFeedParserDelegate>{//Displaying    Nsarray *itemstodisplay;     *formatter;} // Properties@property (nonatomic, Strong) Nsarray *Itemstodisplay; @end

# RSSLISTCONTROLLER.M

 @implementation Rsslistcontroller 

-(Nsinteger) Numberofsectionsintableview :(uitableview *) tableview{ // Return the number of sections. return 1
-(Nsinteger)TableView: (numberofrowsinsection:(nsinteger) section{    //  Return  The number of rows in sections.    itemstodisplay.count;;}  
- (UITableViewCell *)TableView: (UITableView *) TableViewCellforrowatindexpath:(Nsindexpath *) indexpath{// Return init TableCell   < span class= "constant" >< Span class= "string" >} 

-(void) TableView: (UITableView *) tableView Didselectrowatindexpath :(Nsindexpath *) Indexpath
{
   < Span style= "color: #008000;" >// Return selected action
}

#pragma mark-editmode
//return Edit Status
-(BOOL) TableView: (UITableView *) TableView Caneditrowatindexpath :(Nsindexpath *) Indexpath
{
// Return can edit. 
returnYES;
}

return Delete style
-(Uitableviewcelleditingstyle) TableView: (UITableView *) TableViewEditingstyleforrowatindexpath:(Nsindexpath *) Indexpath
{
   // Return Delete style
returnUitableviewcelleditingstyledelete;
}

Return Delete title
-(NSString *) TableView: (UITableView *) TableViewTitlefordeleteconfirmationbuttonforrowatindexpath:(Nsindexpath *) Indexpath {
   // Return Delete name
return@ "Delete";
}

Delete action
-(void) TableView: (UITableView *) TableView Commiteditingstyle: (uitableviewcelleditingstyle) EditingstyleForrowatindexpath:(Nsindexpath *) Indexpath
{
// Return Delete action
}
@end

iOS Development Uitableviewcontroller

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.