×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: Objective-C
Posted by: Black Light
Added: Mar 3, 2013 11:49 AM
Views: 29
Tags: no tags
http://developer.apple.com/library/ios/#samplecode/Reachability/Introduction/Intro.html
https://github.com/tonymillion/Reachability
  1.     Reachability* internetReach = [Reachability reachabilityForInternetConnection];
  2.    
  3.     NetworkStatus netStat=[internetReach currentReachabilityStatus];
  4.    
  5.     if (netStat!=NotReachable)
  6.     {
  7. // internet is available
  8. }
  9. else
  10. {
  11. // internet is not available
  12. }
  13.