Re: [android-developers] Re: Internet connection is not working in emulator

2010-10-04 Thread Viral Brahmbhatt
Anyone having any solutions I am still not able to crack this

On Sat, Sep 25, 2010 at 3:19 AM, Viral Brahmbhatt viralbrahmbh...@gmail.com
 wrote:

 Hi,

 I am using Win XP, and i have wireless internet connection on my laptop.
 there is no proxy


 On Sat, Sep 25, 2010 at 2:44 AM, DanH danhi...@ieee.org wrote:

 Here are a few ideas:


 http://stackoverflow.com/questions/2039964/how-to-connect-android-emulator-to-the-internet

 Would help to know what OS you're running, whether hard-wired or
 wireless, whether you're using a proxy, etc.

 On Sep 13, 1:01 am, viral viralbrahmbh...@gmail.com wrote:
  Hi,
 
  I am not able to run the internet from my android emulator. whenever I
  try to run my browser i am getting following error on various
  platforms
 
  Following are some of the entries in log window.
 
  Android emulator 2.2:
  ERROR/ActivityThread(269): Failed to find provider info for
  com.google.settings
  onReceivedError -7
 http://www.google.com/m?client=ms-android-googlesource=android-home
  The server failed to communicate. Try again later.
 
  Android emulator 2.1:
  ERROR/ActivityThread(114): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(114): Can't update stat PHONE_GPRS_ATTEMPTED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
  ERROR/ActivityThread(114): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(114): Can't update stat PHONE_GPRS_CONNECTED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
 
  ERROR/ActivityThread(229): Failed to find provider info for
  com.google.settings
  onReceivedError -7
 http://www.google.com/m?client=ms-android-googlesource=android-home
  The server failed to communicate. Try again later.
 
  Android emulator 1.6:
  ERROR/ActivityThread(122): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(122): Can't update stat PHONE_GSM_REGISTERED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
 
  ERROR/ActivityThread(122): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(122): Can't update stat PHONE_GPRS_ATTEMPTED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
  ERROR/ActivityThread(122): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(122): Can't update stat PHONE_GPRS_CONNECTED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
 
  ERROR/ActivityThread(302): Failed to find provider info for
  com.google.settings
  WARN/ActivityManager(77): Unable to start service Intent
  { cmp=com.google.android.googleapps/.GoogleLoginService }: not found
  ERROR/browser(302): onReceivedError -7
 http://www.google.com/m?client=ms-android-google
  The server failed to communicate. Try again later.
 
  Android emulator 1.5:
  ERROR/ActivityThread(640): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(640): Can't update stat PHONE_GSM_REGISTERED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
 
  ERROR/ActivityThread(640): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(640): Can't update stat PHONE_GPRS_ATTEMPTED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
  ERROR/ActivityThread(640): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(640): Can't update stat PHONE_GPRS_CONNECTED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
 
  ERROR/ActivityThread(846): Failed to find provider info for
  com.google.settings
  ERROR/browser(846): onReceivedError -7
 http://www.google.com/m?client=ms-null
  The server failed to communicate. Try again later.
 
  Please let me know if any one has having any solution for this issue
 
  Thanks in advance
 
  Regards,
  Viral

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




 --
 *Regards,
 Viral*




-- 
*Regards,
Viral*

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Internet connection is not working in emulator

2010-09-24 Thread Viral Brahmbhatt
Hi,

I am using Win XP, and i have wireless internet connection on my laptop.
there is no proxy

On Sat, Sep 25, 2010 at 2:44 AM, DanH danhi...@ieee.org wrote:

 Here are a few ideas:


 http://stackoverflow.com/questions/2039964/how-to-connect-android-emulator-to-the-internet

 Would help to know what OS you're running, whether hard-wired or
 wireless, whether you're using a proxy, etc.

 On Sep 13, 1:01 am, viral viralbrahmbh...@gmail.com wrote:
  Hi,
 
  I am not able to run the internet from my android emulator. whenever I
  try to run my browser i am getting following error on various
  platforms
 
  Following are some of the entries in log window.
 
  Android emulator 2.2:
  ERROR/ActivityThread(269): Failed to find provider info for
  com.google.settings
  onReceivedError -7
 http://www.google.com/m?client=ms-android-googlesource=android-home
  The server failed to communicate. Try again later.
 
  Android emulator 2.1:
  ERROR/ActivityThread(114): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(114): Can't update stat PHONE_GPRS_ATTEMPTED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
  ERROR/ActivityThread(114): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(114): Can't update stat PHONE_GPRS_CONNECTED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
 
  ERROR/ActivityThread(229): Failed to find provider info for
  com.google.settings
  onReceivedError -7
 http://www.google.com/m?client=ms-android-googlesource=android-home
  The server failed to communicate. Try again later.
 
  Android emulator 1.6:
  ERROR/ActivityThread(122): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(122): Can't update stat PHONE_GSM_REGISTERED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
 
  ERROR/ActivityThread(122): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(122): Can't update stat PHONE_GPRS_ATTEMPTED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
  ERROR/ActivityThread(122): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(122): Can't update stat PHONE_GPRS_CONNECTED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
 
  ERROR/ActivityThread(302): Failed to find provider info for
  com.google.settings
  WARN/ActivityManager(77): Unable to start service Intent
  { cmp=com.google.android.googleapps/.GoogleLoginService }: not found
  ERROR/browser(302): onReceivedError -7
 http://www.google.com/m?client=ms-android-google
  The server failed to communicate. Try again later.
 
  Android emulator 1.5:
  ERROR/ActivityThread(640): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(640): Can't update stat PHONE_GSM_REGISTERED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
 
  ERROR/ActivityThread(640): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(640): Can't update stat PHONE_GPRS_ATTEMPTED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
  ERROR/ActivityThread(640): Failed to find provider info for
  android.server.checkin
  WARN/Checkin(640): Can't update stat PHONE_GPRS_CONNECTED:
  java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/stats
 
  ERROR/ActivityThread(846): Failed to find provider info for
  com.google.settings
  ERROR/browser(846): onReceivedError -7
 http://www.google.com/m?client=ms-null
  The server failed to communicate. Try again later.
 
  Please let me know if any one has having any solution for this issue
 
  Thanks in advance
 
  Regards,
  Viral

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
*Regards,
Viral*

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Internet Connection Bug Or Error ??

2010-08-25 Thread tarek attia
On Sat, Aug 21, 2010 at 1:33 AM, tarek attia tarek.m.at...@gmail.comwrote:



 On Sat, Aug 21, 2010 at 1:43 AM, Miguel Morales 
 therevolti...@gmail.comwrote:

 Did you not read my reply?  Try pinging an ip that's always up like
 4.2.2.2 or similar.
 So you'll need a few levels of checks, first the normal check you're
 doing now.  And then an internet reachability test to test if you can
 reach the internet.

 Thank you very much :) .I did it as you suggested.This is what worked for
 me :-

 try {
 address = InetAddress.getByName(www.google.com);


* checkConnection = address.isReachable(6);*



 this method always returns false in android due to Linux privileges and
 something like this.So you can use HTTP timeout  instead to check the
 Internet connection.



   }




 catch (UnknownHostException e)
  {
guiHandler.post(noConnectionAlert);
   }
 catch (IOException e)
  {
guiHandler.post(noConnectionAlert);
   }


 This isn't a bug in android, or some sort of error.  This is a common
 functionality in all software.  If you're connected to your router,
 but your router isn't connected to the internet.  All the software
 will think it's connected to the internet and try to connect forever.

  (At least for software that doesn't run the check I've told you)


 On Fri, Aug 20, 2010 at 3:38 PM, tarek attia tarek.m.at...@gmail.com
 wrote:
 
 
  On Sat, Aug 21, 2010 at 12:43 AM, Mark Murphy mmur...@commonsware.com
  wrote:
 
  On Fri, Aug 20, 2010 at 4:50 PM, tarek attia tarek.m.at...@gmail.com
  wrote:
   Any Idea???
 
  One idea is for you to have patience and not expect immediate
  responses to your emails.
 
  Sorry for this,but I have been with this error long time .
 
 
 
 
  You can try requestRouteToHost(), but I've seen some reports to
  suggest that it does not work very well.
 
  The best option is for you to simply try some operation on whatever
  server you are trying to reach. For example, download a small graphic
  from the Web site if you are trying to access that site's Web service.
 
   What if this server is down at this time!!! I want to show the reason
 of
  the disability either the no internet connection or the server is down
 ??
 
  --
  Mark Murphy (a Commons Guy)
  http://commonsware.com | http://github.com/commonsguy
  http://commonsware.com/blog | http://twitter.com/commonsguy
 
  _The Busy Coder's Guide to Android Development_ Version 3.1 Available!
 
  --
  You received this message because you are subscribed to the Google
  Groups Android Developers group.
  To post to this group, send email to
 android-developers@googlegroups.com
  To unsubscribe from this group, send email to
  android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
  For more options, visit this group at
  http://groups.google.com/group/android-developers?hl=en
 
 
  --
  tarek
 
  --
  You received this message because you are subscribed to the Google
  Groups Android Developers group.
  To post to this group, send email to
 android-developers@googlegroups.com
  To unsubscribe from this group, send email to
  android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
  For more options, visit this group at
  http://groups.google.com/group/android-developers?hl=en



 --
 http://developingthedream.blogspot.com/,
 http://diastrofunk.com,
 http://www.youtube.com/user/revoltingx, ~Isaiah 55:8-9

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




 --
 tarek




-- 
tarek

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Internet Connection Bug Or Error ??

2010-08-21 Thread Kostya Vasilyev
 Besides, network connectivity can become unavailable at any time, like 
in the middle of your download.


So checking to see if it's available at some point in time is no 
substitute for error handling in networking code.


-- Kostya

21.08.2010 1:43, Mark Murphy пишет:

On Fri, Aug 20, 2010 at 4:50 PM, tarek attiatarek.m.at...@gmail.com  wrote:

Any Idea???

One idea is for you to have patience and not expect immediate
responses to your emails.

You can try requestRouteToHost(), but I've seen some reports to
suggest that it does not work very well.

The best option is for you to simply try some operation on whatever
server you are trying to reach. For example, download a small graphic
from the Web site if you are trying to access that site's Web service.




--
Kostya Vasilev -- WiFi Manager + pretty widget -- http://kmansoft.wordpress.com

--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: Internet Connection Bug Or Error ??

2010-08-20 Thread Mark Murphy
On Fri, Aug 20, 2010 at 4:50 PM, tarek attia tarek.m.at...@gmail.com wrote:
 Any Idea???

One idea is for you to have patience and not expect immediate
responses to your emails.

You can try requestRouteToHost(), but I've seen some reports to
suggest that it does not work very well.

The best option is for you to simply try some operation on whatever
server you are trying to reach. For example, download a small graphic
from the Web site if you are trying to access that site's Web service.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

_The Busy Coder's Guide to Android Development_ Version 3.1 Available!

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: Internet Connection Bug Or Error ??

2010-08-20 Thread Miguel Morales
This is a problem for all kinds of software.  Including PC software.
It is not something unique to Android.
The only solution I can think of is try to ping or reach an ip that is
always up.

On Fri, Aug 20, 2010 at 2:43 PM, Mark Murphy mmur...@commonsware.com wrote:
 On Fri, Aug 20, 2010 at 4:50 PM, tarek attia tarek.m.at...@gmail.com wrote:
 Any Idea???

 One idea is for you to have patience and not expect immediate
 responses to your emails.

 You can try requestRouteToHost(), but I've seen some reports to
 suggest that it does not work very well.

 The best option is for you to simply try some operation on whatever
 server you are trying to reach. For example, download a small graphic
 from the Web site if you are trying to access that site's Web service.

 --
 Mark Murphy (a Commons Guy)
 http://commonsware.com | http://github.com/commonsguy
 http://commonsware.com/blog | http://twitter.com/commonsguy

 _The Busy Coder's Guide to Android Development_ Version 3.1 Available!

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en



-- 
http://developingthedream.blogspot.com/,
http://diastrofunk.com,
http://www.youtube.com/user/revoltingx, ~Isaiah 55:8-9

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: Internet Connection Bug Or Error ??

2010-08-20 Thread tarek attia
On Sat, Aug 21, 2010 at 1:25 AM, DanH danhi...@ieee.org wrote:

 First you have to define connected to the internet.  You might be
 connected to the local router, eg, but it might not have a route out.
 You might even have a connection to a large network (eg, a
 university), but not be able to get past some firewall to the rest of
 the world.

 I mean by Connected to the internet to have an internet Gateway .I
want to ensure that I'm connected to the internet not just a network without
an internet gateway



 On Aug 20, 2:33 pm, tarek attia tarek.m.at...@gmail.com wrote:
  Hi all,
 
  In my application I must use the internet connection ,so I check it first
  before I open an URL connection using this :-
 
  public boolean IsConnectedToNetwork(ConnectivityManager conManager)
   {
NetworkInfo allNetworkInfo = conManager.getActiveNetworkInfo();
NetworkInfo currNetworkInfo;
boolean anythingConnected = false;
  for (int i = 0; i  allNetworkInfo.length; i++)
  {
 currNetworkInfo = allNetworkInfo[i];
 
 if (currNetworkInfo.getState() == NetworkInfo.State.CONNECTED)
  {
 anythingConnected=true;
  }
 
  }
 
   return anythingConnected;
   }
 
  However this code runs well when I connected to either the operator
 internet
  Or to a Wi-fi network .
 
  But when I'm connected to the operator but without credit and no internet
  the mobile also sees it as there's internet,or even connected to a Wi-fi
  network but without internet gateway it also sees as if it's connected to
  the internet
 
  Any Idea how can ensure that I'm connected to the internet ??
 
  --
 
  tarek

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
tarek

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Internet Connection Bug Or Error ??

2010-08-20 Thread tarek attia
On Sat, Aug 21, 2010 at 12:43 AM, Mark Murphy mmur...@commonsware.comwrote:

 On Fri, Aug 20, 2010 at 4:50 PM, tarek attia tarek.m.at...@gmail.com
 wrote:
  Any Idea???

 One idea is for you to have patience and not expect immediate
 responses to your emails.

Sorry for this,but I have been with this error long time .




You can try requestRouteToHost(), but I've seen some reports to
 suggest that it does not work very well.

 The best option is for you to simply try some operation on whatever
 server you are trying to reach. For example, download a small graphic
 from the Web site if you are trying to access that site's Web service.

  What if this server is down at this time!!! I want to show the reason of
the disability either the no internet connection or the server is down ??

 --
 Mark Murphy (a Commons Guy)
 http://commonsware.com | http://github.com/commonsguy
 http://commonsware.com/blog | http://twitter.com/commonsguy

 _The Busy Coder's Guide to Android Development_ Version 3.1 Available!

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
tarek

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Internet Connection Bug Or Error ??

2010-08-20 Thread Mark Murphy
On Fri, Aug 20, 2010 at 6:38 PM, tarek attia tarek.m.at...@gmail.com wrote:
  What if this server is down at this time!!!

Then you cannot communicate to it.

 I want to show the reason of
 the disability either the no internet connection or the server is down ??

Then try a second server.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

_The Busy Coder's Guide to Android Development_ Version 3.1 Available!

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: Internet Connection Bug Or Error ??

2010-08-20 Thread Miguel Morales
Did you not read my reply?  Try pinging an ip that's always up like
4.2.2.2 or similar.
So you'll need a few levels of checks, first the normal check you're
doing now.  And then an internet reachability test to test if you can
reach the internet.

This isn't a bug in android, or some sort of error.  This is a common
functionality in all software.  If you're connected to your router,
but your router isn't connected to the internet.  All the software
will think it's connected to the internet and try to connect forever.

 (At least for software that doesn't run the check I've told you)


On Fri, Aug 20, 2010 at 3:38 PM, tarek attia tarek.m.at...@gmail.com wrote:


 On Sat, Aug 21, 2010 at 12:43 AM, Mark Murphy mmur...@commonsware.com
 wrote:

 On Fri, Aug 20, 2010 at 4:50 PM, tarek attia tarek.m.at...@gmail.com
 wrote:
  Any Idea???

 One idea is for you to have patience and not expect immediate
 responses to your emails.

 Sorry for this,but I have been with this error long time .




 You can try requestRouteToHost(), but I've seen some reports to
 suggest that it does not work very well.

 The best option is for you to simply try some operation on whatever
 server you are trying to reach. For example, download a small graphic
 from the Web site if you are trying to access that site's Web service.

  What if this server is down at this time!!! I want to show the reason of
 the disability either the no internet connection or the server is down ??

 --
 Mark Murphy (a Commons Guy)
 http://commonsware.com | http://github.com/commonsguy
 http://commonsware.com/blog | http://twitter.com/commonsguy

 _The Busy Coder's Guide to Android Development_ Version 3.1 Available!

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en


 --
 tarek

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en



-- 
http://developingthedream.blogspot.com/,
http://diastrofunk.com,
http://www.youtube.com/user/revoltingx, ~Isaiah 55:8-9

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: Internet Connection Bug Or Error ??

2010-08-20 Thread tarek attia
On Sat, Aug 21, 2010 at 1:43 AM, Miguel Morales therevolti...@gmail.comwrote:

 Did you not read my reply?  Try pinging an ip that's always up like
 4.2.2.2 or similar.
 So you'll need a few levels of checks, first the normal check you're
 doing now.  And then an internet reachability test to test if you can
 reach the internet.

 Thank you very much :) .I did it as you suggested.This is what worked for
me :-

try {
address = InetAddress.getByName(www.google.com);
checkConnection = address.isReachable(6);
  }
catch (UnknownHostException e)
 {
   guiHandler.post(noConnectionAlert);
  }
catch (IOException e)
 {
   guiHandler.post(noConnectionAlert);
  }


 This isn't a bug in android, or some sort of error.  This is a common
 functionality in all software.  If you're connected to your router,
 but your router isn't connected to the internet.  All the software
 will think it's connected to the internet and try to connect forever.

  (At least for software that doesn't run the check I've told you)


 On Fri, Aug 20, 2010 at 3:38 PM, tarek attia tarek.m.at...@gmail.com
 wrote:
 
 
  On Sat, Aug 21, 2010 at 12:43 AM, Mark Murphy mmur...@commonsware.com
  wrote:
 
  On Fri, Aug 20, 2010 at 4:50 PM, tarek attia tarek.m.at...@gmail.com
  wrote:
   Any Idea???
 
  One idea is for you to have patience and not expect immediate
  responses to your emails.
 
  Sorry for this,but I have been with this error long time .
 
 
 
 
  You can try requestRouteToHost(), but I've seen some reports to
  suggest that it does not work very well.
 
  The best option is for you to simply try some operation on whatever
  server you are trying to reach. For example, download a small graphic
  from the Web site if you are trying to access that site's Web service.
 
   What if this server is down at this time!!! I want to show the reason of
  the disability either the no internet connection or the server is down ??
 
  --
  Mark Murphy (a Commons Guy)
  http://commonsware.com | http://github.com/commonsguy
  http://commonsware.com/blog | http://twitter.com/commonsguy
 
  _The Busy Coder's Guide to Android Development_ Version 3.1 Available!
 
  --
  You received this message because you are subscribed to the Google
  Groups Android Developers group.
  To post to this group, send email to
 android-developers@googlegroups.com
  To unsubscribe from this group, send email to
  android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
  For more options, visit this group at
  http://groups.google.com/group/android-developers?hl=en
 
 
  --
  tarek
 
  --
  You received this message because you are subscribed to the Google
  Groups Android Developers group.
  To post to this group, send email to android-developers@googlegroups.com
  To unsubscribe from this group, send email to
  android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
  For more options, visit this group at
  http://groups.google.com/group/android-developers?hl=en



 --
 http://developingthedream.blogspot.com/,
 http://diastrofunk.com,
 http://www.youtube.com/user/revoltingx, ~Isaiah 55:8-9

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
tarek

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Internet Connection

2010-01-28 Thread Sasikumar.S
Thank u for ur reply.

On Thu, Jan 28, 2010 at 3:15 PM, Chander Pechetty cspeche...@gmail.comwrote:

 use ConnectivityManager and probably add the permission -
 ACCESS_NETWORK_STATE to manifest file

 On Jan 28, 12:31 pm, Sasikumar.S sasikumar.it1...@gmail.com wrote:
  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 ustcchenj...@gmail.com
 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 sasikumar.it1...@gmail.com写道:
 
   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 ustcchenj...@gmail.com
 
   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 sasikumar.it1...@gmail.com 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
 android-developers@googlegroups.com
   To unsubscribe from this group, send email to
   android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 android-developers%2bunsubscr...@googlegroups.comandroid-developers%252bunsubscr...@googlegroups.com
 
   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 android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
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 android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Internet Connection

2010-01-28 Thread Sasikumar.S
ok.. Thank U

On Thu, Jan 28, 2010 at 3:37 PM, Retrodis mattwoodfi...@googlemail.comwrote:

 ConnectivityManager cm = (ConnectivityManager) this.getSystemService
 (Context.CONNECTIVITY_SERVICE);
 NetworkInfo ni = cm.getActiveNetworkInfo();
 if(ni != null) {

 }

 On Jan 28, 9:46 am, Sasikumar.S sasikumar.it1...@gmail.com wrote:
  Thank u for ur reply.
 
  On Thu, Jan 28, 2010 at 3:15 PM, Chander Pechetty cspeche...@gmail.com
 wrote:
 
 
 
 
 
   use ConnectivityManager and probably add the permission -
   ACCESS_NETWORK_STATE to manifest file
 
   On Jan 28, 12:31 pm, Sasikumar.S sasikumar.it1...@gmail.com wrote:
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 ustcchenj...@gmail.com
   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 sasikumar.it1...@gmail.com写道:
 
 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 ustcchenj...@gmail.com
 
 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 sasikumar.it1...@gmail.com
 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
   android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.comandroid-developers%2Bunsubs
 cr...@googlegroups.com
   android-developers%2bunsubscr...@googlegroups.comandroid-developers%252bunsubscr...@googlegroups.comandroid-developers%252Bu
 nsubscr...@googlegroups.com
 
 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
 android-developers@googlegroups.com
   To unsubscribe from this group, send email to
   android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.comandroid-developers%2Bunsubs
 cr...@googlegroups.com
   For more options, visit this group at
  http://groups.google.com/group/android-developers?hl=en
 
  --
  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 android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
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 android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Internet Connection

2010-01-27 Thread Sasikumar.S
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 ustcchenj...@gmail.com

 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 sasikumar.it1...@gmail.com 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 android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
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 android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Internet Connection

2010-01-27 Thread Sasikumar.S
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 ustcchenj...@gmail.com 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 sasikumar.it1...@gmail.com写道:

 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 ustcchenj...@gmail.com

 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 sasikumar.it1...@gmail.com 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 android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
 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 android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en