Thank You for ur reply Jian, I will check it and tell to you.
On Thu, Jan 28, 2010 at 12:55 PM, Jian Chen <[email protected]> wrote: > ah, then let us come to the question how to check internet connection is > not enabled or not. > Hope that below code will help. > @Override > public void onStart() { > super.onStart(); > ConnectivityManager cMgr = (ConnectivityManager) > this.getSystemService(Context.CONNECTIVITY_SERVICE); #1 > NetworkInfo netInfo = cMgr.getActiveNetworkInfo(); #2 > this.status.setText(netInfo.toString()); > } > > ConnectivityManager can help u know current network status. > > 在 2010年1月28日 下午3:16,Sasikumar.S <[email protected]>写道: > > Hi alligator, >> >> Thank u for ur reply. >> >> I know how to create a alert dialog.. >> I need how to check whether internet connection is enabled or not?.. >> >> 2010/1/28 alligator <[email protected]> >> >>> I think an alertdiaglog can do it. >>> >>> Dialog dialog=new AlertDialog.Builder(this) >>> .setTitle("about") >>> .setMessage("author:ddd\n") >>> .setPositiveButton("OK", new DialogInterface.OnClickListener() >>> { >>> public void onClick(DialogInterface dialog, int >>> whichButton){ >>> return; >>> } >>> }) >>> .create(); >>> dialog.show(); >>> >>> On 1月28日, 下午1时40分, "Sasikumar.S" <[email protected]> wrote: >>> > Hi, >>> > >>> > How to find whether internet connection is working or not in android >>> > emulator?... >>> > >>> > I'm doing one RSS Program. >>> > When internet connection is not enable the RSS feed is not fetching the >>> data >>> > and it is showing error. >>> > So if internet connection is not enable i need to display a alert that >>> > "Internet Connection Not Enabled" >>> > >>> > How to do this?... >>> > >>> > -- >>> > Thanks & Regards >>> > Sasikumar.S >>> >>> -- >>> You received this message because you are subscribed to the Google >>> Groups "Android Developers" group. >>> To post to this group, send email to [email protected] >>> To unsubscribe from this group, send email to >>> [email protected]<android-developers%[email protected]> >>> For more options, visit this group at >>> http://groups.google.com/group/android-developers?hl=en >> >> >> >> >> -- >> Thanks & Regards >> Sasikumar.S >> > > -- Thanks & Regards Sasikumar.S -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

