简体   繁体   English

在Java程序上执行adb命令

[英]Executing adb command on java program

i made a java tool which calls certain adb command to download an app from market. 我制作了一个Java工具,该工具调用了某些adb命令来从市场下载应用程序。 When i made it into a runnable JAR, its executing fine in the system where i made it, but when i try it on other system the adb commands just fail to execute Any suggestions 当我把它做成一个可运行的JAR,在系统中执行的地方罚款我做了,但是当我尝试在其他系统中的亚行命令,只是无法执行任何建议

AFAIK executable jar donot work on android. AFAIK可执行jar在Android上不起作用。 Sun Java and Android are not compatible Sun Java和Android不兼容

Have you included the Adb executable and the related dll in your solution? 您是否在解决方案中包含了Adb可执行文件和相关的dll? You should include it for 2 main reasons: 您应包括以下两个主要原因:

  1. if the system hasn't the android sdk, it doen't have adb 如果系统没有android sdk,则没有adb
  2. the path to adb can differ from one computer to another. 从一台计算机到另一台计算机,adb的路径可能不同。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM