开发者

Hello Android works on my phone but not on Emulator

开发者 https://www.devze.com 2023-03-07 03:30 出处:网络
I am trying to learn about Android development. I have installed Eclipse (3.6.2) the ADT plugin (10.0.1) and the Android SDK (r11 off the official site) all are installed as 32 bit but my OS is Window

I am trying to learn about Android development. I have installed Eclipse (3.6.2) the ADT plugin (10.0.1) and the Android SDK (r11 off the official site) all are installed as 32 bit but my OS is Windows 7 64-bit.

What happens is I run my app (HelloAndroid) and the emulator and I see the main wallpaper screen but then then nothing happens! I have looked on the emulator for the app and cannot find it anywhere.

My console output is shown below...

[2011-05-20 19:14:20 - HelloAndroid] ------------------------------
[2011-05-20 19:14:20 - HelloAndroid] Android Launch!
[2011-05-20 19:14:20 - HelloAndroid] adb is running normally.
[2011-05-20 19:14:20 - HelloAndroid] Performing com.example.helloandroid.HelloAndroid activity launch
[2011-05-20 19:14:20 - HelloAndroid] Automatic Target Mode: launching new emulator with compatible AVD 'Android2.1'
[2011-05-20 19:14:20 - HelloAndroid] Launching a new emulator with Virtual Device 'Android2.1'

My AVD (Android Virtual Device) is set up as the tutorial suggests and the target is Android2.1-update1-API Level 7.

I have installed this app on my phone (HTC Hero, Android 2.1) and it works fine, but before I try and write other appl开发者_如何转开发ications I need to get the emulator working, has anyone encountered this issue before?

I have looked online and cannot find a solution that solves my problem.

Thanks for your help in advance.


You can use adb to install your app. Find the bin directory in your eclipse workspace. There should be a YOUR_PROJECT_NAME.apk file there. To install it, from the command line, run:

adb install -r YOUR_PROJECT_NAME.apk

You will need adb in your path.


Start the emulator, switch to the logcat view in Eclipse (Window -> show view -> other ... -> logcat).

Clear the console output for logcat.

Try to deploy your application.

What does the output in logcat say? Does it display an error message?

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号