I am very new to android.I am using android 2.3.I want to know how to get location through gps or network provider on the android emulator.When I run my application on the emulator,it does not give me the name of the network provider but displays "network".I am creating an application which requires user's current location. can anyone please help me to do it and even how i can test if it works on emulator.
Asked
Active
Viewed 673 times
0
-
Maybe your answer can be found [here](http://stackoverflow.com/questions/2279647/how-to-emulate-gps-location-in-the-android-emulator). At least the gps emulation part. – Daniel Higueras Mar 19 '11 at 19:25
1 Answers
1
Two parts
Emulator will not give you a location. However, you can simulate a location. If you are using Eclipse, go to DDMS perspective and in the left side, you will see Emulator Controls. Scroll down to see Location Controls. You can enter location coords here.
You need to download Google API for Android (This is different from Android API). Go to your Android SDK and AVD Manager (in Eclipse this is under Menu 'Window'). Select Available Packages --> Third party Add-Ons --> Google Inc and select the API versions you want. Run the GPS emulation using these emulator

GSree
- 2,890
- 1
- 23
- 25