android-emulator

java.net.ConnectException - Connection Refused Android Emulator

我的梦境 提交于 2019-12-20 10:28:44
问题 I have an android emulator I'm running from eclipse and just trying to connect to a simple socket server I wrote in .NET (c#). The server is running on the same machine on port 4505. I am able to telnet (through PuTTy) to the server and it works just fine, but when I try to connect to the server with the android emulator I get a: java.net.ConnectException - localhost/127.0.0.1:4505 - Connection refused at org.apache.harmony.luni.net error. I'm assuming this is because the emulator is on a

How to use global class variables in android

坚强是说给别人听的谎言 提交于 2019-12-20 06:28:53
问题 Hi I am doing one app here. I'm using global class varibles. It's working well, but if I'm using more globalclass variables I'm getting memory exceptions some times. I tried this: public class SecondClass extends Activity { @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.second); TextView tv = (TextView)findViewById(R.id.tv); tv.setText("Global String : " + GlobalClass.myVal); } } class GlobalClass extends Application {

How to run android app in emulator by rewriting old databases?

江枫思渺然 提交于 2019-12-20 06:26:14
问题 When I always run app to test in emulator from Eclipse , by default it never uninstalls previous one. It will maintain previous copy of database and files of the same app and run a new compiled code. What if I want to remove all app related files, databases every time I compile and run it to test? Any settings for this in Eclipse ? I want to avoid the step of manually uninstalling it before every run. Thanks. 回答1: You can have a command prompt window open, and before launching, execute: adb

AMD Processor Hax Kernel is not installed

隐身守侯 提交于 2019-12-20 05:15:33
问题 I'm having problems with the Emulator on Android Studio. First of all, when I'm trying to execute my app with the Android Studio emulator, appears me the following log: emulator: ERROR: x86_64 emulation currently requires hardware acceleration! Please ensure Intel HAXM is properly installed and usable. CPU acceleration status: HAX kernel module is not installed! Ok, searching I found that I have to install intelhaxm-android.exe So I did it, but appers me a pop-up saying that my computer does

IndexOutOfBoundsException error on Android device not on emulator

◇◆丶佛笑我妖孽 提交于 2019-12-20 03:54:12
问题 Here is the problem that I am dealing with right now with my Android App. Program works fine on emulator without any error but errors out on real device running same OS. I have a App Widget Update Service that updates my Widget. This service checks whether the widget is on the screen otherwise does not go through the update process. Works fine on emulator. Every time the widget has to be updated in the OnReceive method I capture the intent in a string variable check_intent which tells me if

gralloc_goldfish(634): Emulator without GPU emulation detected

风流意气都作罢 提交于 2019-12-20 03:43:18
问题 I am using android SDK 4.0.3 and I'm trying to run a simple program in which I'm trying to switch from one page to another page using an Intent (By passing intent object as: Intent intent = new Intent(getApplicationContext(),SecondActivity.class); startActivity(intent); ) [Also, I have 3GB RAM] but when I run the program it gives something like this in DDMS: 01-23 01:58:23.892: D/gralloc_goldfish(634): Emulator without GPU emulation detected. 01-23 01:58:45.482: D/AndroidRuntime(634):

Emulator unable to connect to internet

可紊 提交于 2019-12-20 03:31:48
问题 My machine is using a WiFi connection for internet, and the LAN card is idle. it's not behind a proxy or firewall, but somehow, my emulator's browser isn't loading any page. meaning that the emulator can't connect to the internet. I searched a lot but with no luck. what might be the possible reasons? Please help. Thanks in Advance!! 回答1: I had the same problem with OS X. I have been working for 2 days now to get the emulator to connect to the internet, all solutions I have read so far (use

Android Studio emulator could not find wglgetextensionsstringarb

人盡茶涼 提交于 2019-12-20 03:27:10
问题 When I try to start the emulator, suddenly I started getting this error everything worked couple of days ago. if I disable GPU acceleration then it works but very slowly. I tried re-enabling virtualization in the bios and it worked once and now I get the same error again.. I have the latest android studio 2.2.1 I have a new graphics card GeForce. this is the error message Hax is enabled init: Could not find wglGetExtensionsStringARB! getGLES2ExtensionString: Could not find GLES 2.x config!

Does the geocoder work on emulators

百般思念 提交于 2019-12-20 02:36:13
问题 I am using the geocoder and it worked just fine on my device but not working on emulators tried it on 2.2 and 4.2.2 didn't work; this is my code: Geocoder myLocation = new Geocoder(AzanTime.this, Locale.getDefault()); List<Address> myList=null; try { myList = myLocation.getFromLocation(latitude,longitude, 1); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } Address address = (Address) myList.get(0); String addressStr = ""; if(address.getAddressLine(0)!=null)

Side loading instant app failed: Reading bundle timed out

倾然丶 夕夏残阳落幕 提交于 2019-12-20 02:34:48
问题 Unable to use Android Emulator, for testing the Instant Apps!! Every-time I'm getting "Side loading instant app failed: Reading bundle timed out." I'm using, Android Studio 3.0 Canary-5 Emulator : Nexus 5X image running Android 6.0 (API level 23), x86, with Google APIs. Google APIs Intel x86 Atom System Image (Revision 21) Note: After updating Android Studio 3.0 (Canary-4 > Canary-5) & Emulator system image from revision (20 > 21) . I'm unable to run the instant App through emulator. Always I