i fetch data via NSURLConnction from a server and want to populate a tableview from fetched array. The data appears in the log from NSURLConnection delegate method but i realized that numberOfRowsInSection of UITableView delegate method(DM) fires before
- (void)connection:(NSURLConnection *)connection didReceiveData:(NSData *)data {}
DM of NSURLConnection. and this causes a problem for me because even tough i get the data properly returned number of rows is allways 0(zero).. How can i solve this issue please share any idea.. Thanks
didRecieveData might be called more than once, and does not indicates that all data is fetched. You should implement a private property on your class such as;
and on your didRecieveData;
After that when your connection is closed