如何在Android的文件导入到SD卡上的模拟器? [英] how to import files into the sdcard on emulator in android?

查看:112
本文介绍了如何在Android的文件导入到SD卡上的模拟器?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想加载一些照片到我在模拟器SD卡的图像。如何做到这一点通过命令prompt.how做到这一点?

i want to load some photos into my sd card image in the emulator. how to do this by command prompt.how to do that?

推荐答案

我发现这是令人难以置信的笨拙,不能很好地工作,但使用的命令是:亚行推yourfile.xxx /sdcard/yourfile.xxx 。对于这个工作,你得有在同一个目录下的文件adb.exe,这是你的SDK目录的工具文件夹,或建立了亚洲开发银行作为全系统识别的命令。 (我不记得如何做到这一点,但我知道这是可以做到)。这还假定你已经设置了一个SD卡通过AVD管理器。然而,我面对这样做时,问题是,有时该文件将出现在与0字节的大小的仿真器。我的意思是,我可以看到在Eclipse中的DDMS文件浏览器中的文件,但这样做的必要的仿真器重新启动后,该文件将被显示为0字节的大小。我找不到为什么发生的模式,但在连续尝试了几次,最终的工作。

I've found it to be incredibly clumsy and not work very well, but the command to use is: adb push yourfile.xxx /sdcard/yourfile.xxx. For this to work you've got to have the file in the same directory as adb.exe, which is in the tools folder of your SDK directory, or have set up adb as a system-wide recognisable command. (I don't remember how to do that, but I know it can be done). This also assumes you've set up an SD card through the AVD manager. However, the problem I faced when doing this is that sometimes the file would appear on the emulator with a size of 0 bytes. What I mean is that I could see the file in the DDMS file browser in Eclipse, but after doing the necessary emulator restart, the files would then be shown with the 0 byte size. I couldn't find a pattern on why that happened, but trying a few times in a row eventually worked.

这篇关于如何在Android的文件导入到SD卡上的模拟器?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆