Android应用程序在手机上运行的步骤
仅用于计算机是Windows操作
1.In Eclipse, you can do this from theApplicationtab when viewing the Manifest (on the right side, setDebuggabletotrue). Otherwise, in theAndroidManifest.xml
file, addandroid:debuggable="true"
to the<application>
element.
我们就直接了当的在Eclipse里,在AndroidManifest.xml中<application>里加上android:debuggable="true"
2.Turn on "USB Debugging" on your device.
On the device, go to the home screen, pressMENU, selectApplications>Development, then enableUSB debugging.
就是把手机的USB调试模式打开,方法是(我以HTC Desire HD为例):Menu>设置>应用程序>开发>勾选”USB调试“
3.If you're developing on Windows, you need to install a USB driver for adb. If you're using an Android Developer Phone (ADP), Nexus One, or Nexus S, see theGoogle Windows USB Driver. Otherwise, you can find a link to the appropriate OEM driver in theOEM USB Driversdocument.
就是把手机用USB线连到电脑上,安装驱动程序,Win7会自动安装,如若没有自动安装,在各手机网站的技术支持里找到驱动并下载。
4.在Eclipse里点Run>Run(或Debug),这时会弹出一个窗口,让你选择用模拟器还是手机来显示,选择手机,再看看手机上是不是出现了运行结果呢?呵呵。
图中第一个是模拟器,第二个就是我的手机,呵呵。
以下是在模拟器上运行的效果:
再来一张手机上的效果展示:
更多相关文章
- android 模拟器 得到GPS
- android中怎么获得所有应用程序的快捷方式
- Android 安装路径问题 -- 导致无法启动模拟器
- Android Studio 3.0 Canary 8无法安装apk到小米手机
- 运行模拟器时 No such file or directory
- android之通过MediaRecorder进行手机录音
- 列出手机中所有的App,点击启动
- android 模拟器使用指导