从 eclipse 运行后,我的应用程序没有出现在 AVD 中
我在 Eclipse 中为 Android 创建了一个小应用程序,当我按“运行”时,会创建一个新的 AVD,Eclipse 告诉我该应用程序已安装在 AVD 上,但我在虚拟设备上找不到它。为什么会这样呢?谢谢
I created a small app in eclipse for android, and when I press "Run", a new AVD is created, eclipse tells me that the app was installed on the AVD, but I can't find it on the virtual device. Why can that be? Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
我认为您可能忘记在清单文件中添加这些行。我在应用程序中遇到了同样的问题,它显示该应用程序已安装,但在模拟器中找不到它。
另请确保从“运行配置”设置目标 AVD。运行->运行配置->目标,然后从列表中选择 AVD,单击“应用”,然后单击“确定”。
希望有帮助。
I think you probably forgot to add these lines in the manifest file. I had the same problem in an app and it showed that the app was installed, but could not find it in the emulator.
Also make sure you set up the target AVD from Run Configurations. Run->Run Configurations-> Target, then select the AVD from list, click Apply, then Ok.
Hope it helps.
在“运行配置”中的“目标”选项卡下,您可以选择“始终提示选择设备”单选按钮。然后,当您使用顶部的绿色运行按钮运行应用程序时,您可以从任何设备中进行选择。 MaxPower47 在以下线程中解决了这个问题:
无法在 AVD 中运行较旧的 Android 目标
In 'Run Configurations', under the 'Target' tab, you can select the 'Always prompt to pick device' radio button. Then when you go to run the app with the green go button at the top, you can choose from any device. MaxPower47 solved this in the following thread:
Can't run older Android targets in AVD
删除之前创建的 avd 并创建一个新的,先启动它,然后运行该应用程序。一个月前我遇到了类似的问题,这对我有用,希望对你也有用。可能是 avd 未注册 eclipse 的 adt 插件并且运行两个模拟器时,apk 无法正确安装。
Delete the previously created avd and make a new one, launch it first and then run the app. I faced a similar problem a month ago and this worked for me, hope it does for you too. Probably a case of avd not registering with the adt plugin of eclipse and with two emulators running, the apk does not install properly.
尝试使用较旧的 AVD,它对我有用
Try to use an older AVD, it worked for me