the apk file working in emulator but not in android device - eclipse

I run an application in Android emulator in my p.c. , it is working properly .
but,
when I connect my Android device with p.c. , then through eclipse , I run the application , eclipse prompt that whether you want to install your application in android emulator or Android device , I choose Android device ,, the device prompt a force to close error !!!!
even in my laptop the application were installed properly , but not working properly ...
what could be the reason ????
my current Android device version is 2.3.6
thanks...

It's hard to say what the issue is because what you described isn't specific. Have you ever been able to install any application on the device? Is it just this one application that doesn't install?
The first things I would check:
Do you have the correct Windows USB driver installed?
The Android developers website has a page dedicated to it ( http://developer.android.com/sdk/oem-usb.html ) but you should check the manufacturer's website for the most up-to-date software.
Do you have the developer settings enabled on the device?
Settings > Applications > Enable Unknown Sources
Settings > Applications > Development > Enable USB Debugging

Related

React native Android Project Not starting in emulator

i just created a react native project on windows, using expo. After Creating the project i ran npm start and then expo start the next logical thing to do is to press the a button which will launch, the project on the android virtual device, but instead it gave me this error Couldn't start project on Android: Error running adb: Error running app. Error: Activity not started, unable to resolve Intent { act=android.intent.action.VIEW dat=exp://192.168.43.148:19000 flg=0x10000000 }
when i tried running it on my android phone with the expo android app it ran smoothly, i don't know what to do please help thanks
I had the same problem and I got it fixed as follows:
Go to SDK Manager in Android studio > SDK Tools and check whether there is any update for Android SDK Build-Tools. If there is any, please make sure you update it.
Close any Android virtual device currently running and then go to Android Studio Virtual Device Manager and wipe the data of your Android virtual device.
Make sure you have enough internal storage allocated for your Android virtual device to install apps.
Check whether Android Debug Bridge utility is installed in your device. If not please install it. To install in mac, I used the below command (Assuming that you have HomeBrew installed in your mac device):
brew install android-platform-tools
Start your Android virtual device ( This step should be done before running the expo development server)
In the Developer options menu of your Android virtual device, make sure USB debugging option is enabled.
Finally, try running the development server by expo start and press on the button to run on your Android emulator.

Visual Studio Code - Flutter : "Device emulator-5554 is offline"

I have just spent an hour reading through similar questions on Stack Overflow, and they are all for Android Studio, not Visual Studio Code. Also, I am doing Flutter development, so don't have access to adb commands, such as adb kill-server.
Everything was fine, unlike I clicked the power button on my emulated Android. Now, when I run/start debug and select active device, I get Failed to launch Nexus 5X API 29 x86: Error: Emulator didn't connect within 60 seconds.
How can I restart the emulated device? When it appears, clicking the power button does not seem to do anything. Is there a flutter terminal command?
Or can I somehow use a different emulator (if so, how)?
I faced the same issue with Android Virtual Device and Memu emulator so I switched to Genymotion.
I am using Genymotion personal edition which works amazingly and it's very light on resources too as compared to AVD and Memu.
You can download Genymotion Personal edition from Genymotion Personal Edition
Apart from Installing emulator Image you should also consider installing the GAPPS bundle in the emulator as it does not comes with it preinstalled. GAPPS will be needed in many apps requiring Google Play Services.
Here are the docs on how to install GAPPS in Genymotion emulator: GAAPS Docs
GAAPS Website
My Genymotion Emulator is Google Pixel 3a, 9.0 API 28.

How to prevent launch Ionic app on emulator

I'm working on ionic App and I'm trying to run App on real Android device, But when I run ionic run android in terminal, I get the following error:
Running command: "C:\Program Files (x86)\nodejs\node.exe"
D:\wamp\www\pars-app\pars-app\hooks\after_prepare\010_add_platform_class.js
D:\wamp\www\pars-app\pars-app
add to body class: platform-android
ANDROID_HOME=D:\Sdk\android-sdk
JAVA_HOME=C:\Program Files\java\jdk1.8.0_45
No target specified, deploying to emulator
ERROR running one or more of the platforms: No emulator images (avds)
found.
1. Download desired System Image by running: "D:\Sdk\android-sdk\tools\android.bat" sdk
2. Create an AVD by running: "D:\Sdk\android-sdk\tools\android.bat" avd HINT: For a faster emulator, use an Intel System Image and install
the HAXM device driver
You may not have the required environment or OS to run this project
How to prevent run app on windows emulator? I want to run app on real device that conected to my computer.
I am using windows 8 and Huawei with Android 4.2.2
::note
I have read these questions, But I didn't got the answer!
Why not work Ionic app testing on android real device?
Ionic run android does not run app on device
ionic run android - configurations not running app on device
As a complement to #OClyde answer, you could try :
adb kill-server
adb start-server
To have infos about these commands :
adb --help
Nb : Sometimes, for a reason i do not know, the connection between my phone and the computer break. Running this fixes it.
To make sure that your app is not installed to an emulator but to your device, take the following steps:
Open up your console and run adb devices. This should give you a list of all devices available (real devices as well as running emulators) to the Android Debug Bridge. If the adb command is not recognized check that you have installed the Android SDK correctly and that you've set all the necessary environment variables accordingly.
The adb devices command might give you output similar to this:
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
This indicates that the ADB wasn't ready before, so in this case just try to un- and replug your device and run adb devices again to see if the device is listed afterwards.
If your device is still not showing, check that USB Debugging is enabled on your device. Therefore you first have to enable developer settings, which you can do by tapping the build number (Settings => About Phone) 7 times (no, that's not a joke ;) ). After that, you'll have the developer options in your settings menu. Open these and check "USB Debugging"
If still your device isn't recognized by the ADB, change the USB connection mode. You can either do this in the developer options as well or tap the notification shown when the phone is connected to your PC. Try MTP as well as PTP, on of those should do the job.
After these steps, it should be nearly impossible that the device is still not recognized by your PC. As soon as there is a phone available, Ionic will install the app on the phone automatically instead of launching an emulator.

Unable to launch Android emulator from Eclipse/Linux

I'm using Eclipse Juno (build 20120920-0800) on openSUSE 12.2 to code Android applications.
I have installed the SDK by uncompressing it into my home directory (if I install the SDK via YaST package I can't download stuff unless I'm root). I installed ADT from Eclipse Marketplace, configured the path of the SDK and configured a couple of emulator configurations.
I can run and debug fine on my phone, and I guess the same applies to my tablet even if I haven't tried yet.
The real problem is that I can't run the emulator. Clicking on the bacarozzo debug icon prompts me to run the application on the device but doesn't show me available emulators.
If I open the device manager I'm shown with the virtual devices I created but I can't just start any. The progress bar reaches the end, I see no emulator screen and if I try to delete the emulator I'm warned that the instance is running... (OK in the screenshot there is only one, I already managed to delete the other)
I urge to test some GUI features in an outdated version of Android. I have done all the field tests of the business logic code in my program on a JB device and I know for sure that code works on any device.
Now I only need to be backward-compatible with preferences and layouts.
How can I start the emulator in Linux?
Just by luck I managed to run the emulator from console
djechelon#RAYNOR:~/android-sdk-linux/tools> ./emulator-arm -avd Emulator_cell
It came to life and Eclipse debug is detecting it as active device

Running the app on Android console Error - Jdeveloper

I am using JDeveloper 11g Release 2. I am trying to run a helloworld code on the Android simulator. But i end up having the following error in the console. This is due to some settings that i have failed to set. Can someone help me to add the settings so i could run the app on the Android Console.
The following Android preference configuration is missing or invalid. Set these options in JDeveloper Preferences on the ADF Mobile panel:
Key and Keystore Password
Android SDK Location
Android Platform Location
(oracle.adfmf.framework.dt.deploy.android.deployers.ValidatePreferencesDeployer)
If you haven't keystore for signing android apps right now as for testing purpose. You should select build mode to Debug rather than Release mode.
Application > Application Properties > Deployment > select your android build profiles or create a new one > Click at Edit button > Android Option > Change Build Mode to Debug
You need to install the Android SDK for Android development and Xcode for iOS development.
FAQ for ADF Mobile: http://www.oracle.com/technetwork/developer-tools/adf/learnmore/adfmobilefaq-1866697.pdf
Here you can find the setup guide for Android :
http://docs.oracle.com/cd/E18941_01/tutorials/MobileTutorial/jdtut_11r2_54_2.html
And the one for iOS :
http://docs.oracle.com/cd/E18941_01/tutorials/MobileTutorial/jdtut_11r2_54_1.html
For Android, make sure your emulator emulates version 4.0 or higher in order to avoid :
The Android emulator emulates ARMv5, which is not supported. The emulator must support ARMv6 or newer
If there is also an error above this stating that it can't write the cwallet.sso try closing Jdeveloper and running as administrator.