Thursday, February 20, 2014

Ask: How to determine whether the 3G network is connected?


Whether mobile or Unicom or Telecom, has been able to determine whether the current connection on?<-! Main posts under Banner (D4) -><-! Posts under the main text (D5) ->
Reply:
This can be done using the system class features

Reply:
Thank you, I continue to look up information see
Reply:
ConnectivityManager connMgr = (ConnectivityManager) getApplicationContext.getSystemService (Context.CONNECTIVITY_SERVICE);
NetworkInfo networkInfo = connMgr.getActiveNetworkInfo ();
By judgment networkInfo is empty, and the type will be able to know whether the network has connected.

Search Figure 123, the quest colored beauties. Download: http://yunpan.cn/Q9XA6D53jQYXi

No comments:

Post a Comment