请我想刷新我的表格的内容,但它不起作用。
- (void)viewDidLoad
{
[super viewDidLoad];
self.title = @"Last News";
[UIApplication sharedApplication].networkActivityIndicatorVisible = YES;
//
NSURL *url = [NSURL URLWithString:@"http://www.apinae.com/json.php"];
NSURLRequest *request = [NSURLRequest requestWithURL:url];
[[NSURLConnection alloc] initWithRequest:request delegate:self];
// test refresh
UIRefreshControl *refreshControl = [[UIRefreshControl alloc] init];
refreshControl.tintColor = [UIColormagentaColor];
self.refreshControl = refreshControl;
// test refresh
}
提前致谢。