开发者

ASIHTTPRequest Loader

I am using asihttprequest to load data from a remote database upon loading a particular view controller. Currently there is a lag or so it seems between the user pressing the button to push a new view controller and the view actually appearing...I think this is the time taken to query the database and. retrieve data.

I would like a UIActivityIndicator to appear over the top of the current view between the startSynchronous method call and the triggering of setDidFinishSelector 开发者_如何学JAVA (the method called when response has been given) - i.e. while the data is loading. I know there is documentation in ASI site but I'm struggling to find any example that help to implement what I need...

How is this possible?


Please go through the link which covers ASIHTTPRequest and has source code for UIActivityIndicator along with that....

also go through the stackoverflow link


I'm a little confused why you need help. In your view put up an activity indicator just before you call startSynchronous, and in the didFinishSelector remove that activity indicator (don't forget to also put in a fail callback and remove it there also).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜