开发者

Issue with the wifi in iPad

I am working on a educational related apps. My app functionality is working well when the WIFI is connected otherwise it is getting crashed.

  1. In my app I am connecting with the server using NSURLRequest class its working.
  2. the download a开发者_Go百科lso not having any problem if the wifi is available. problem rectification: I have to know weather the my app device is connected with external network or not.

So, how can I know my app is connected with the wifi or not?


The following link consists source code, in which it consists how to check the reachability. That means the wifi or any network is connected of not.

http://developer.apple.com/library/ios/#samplecode/Reachability/Introduction/Intro.html


Apple provides sample code called "Reachability" to detect when the network is available. That would be a good starting point, though a quick Google should locate some alternatives.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜