致电或启动外部应用程序的Andr​​oid [英] Call or start external Application Android

查看:100
本文介绍了致电或启动外部应用程序的Andr​​oid的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

HI到每一个人...

HI to every one...

我工作的一个应用程序,我想在我的应用程序启动或呼叫它由pressing例如按钮的外部应用程序...

I'm working on a Application and I would like to start or call an external application from it by pressing for example a button...on my application.

我想调用应用程序是一个开源的应用程序。

the application I would like to call is an open source application.

我读过官方Android网站上也可以做到这一点,但还没有找到如何做到这一点的任何建议。

I've read on the official android website it is possible to do it but haven't found any suggestion on how to do it.

我的方法:

所以想对我自己,我用一个Intent动作和一个按钮...像这样

So trying on my own I've used an Intent Action and a button...like this

 Intent i=new Intent(android.content.Intent.ACTION_VIEW);  

 startActivity(i); (when the button is pressed...with onClickListener)

结果:

,将出现一个窗口,邀请我选择上市方案,如之一来完成我猜的行动:

when the button is pressed, A window appears which invites me to complete the Action I guess by choosing one of the Listed programs such as:

-Gstr 
-Import Ics
-Market
-Music
-Mail (com.htc.android.mail) and so on...but not the API I was looking for...

当我选择GSTR(我猜是应用程序管理器),然后打开另一个窗口

when I choose Gstr(I guess is the application manager) then opens another window

这显示了安装的应用程序列表。从那里,我发现我的应用

which shows a list of Installed Applications. From there I find the Application I was

寻找,并(在其上的图标......长pressing)

looking for and starts it (by long pressing on it's Icon...)

问题:

我想直接点击一个按钮启动外部应用程序我

I would like to start the external Application directly by clicking on a button on my

应用程序,而不经过数百人......有没有一种方法来实现。

application without passing through hundreds of others... Is there a way to achieve

为此编码?

感谢您的建议...

推荐答案

这是不是一个真正的有效的情况。你将如何确保用户安装了开源应用程序?你现在有什么技术上做到这一点,因为你没有他们已经安装了哪些应用程序的控制正确的方式 - 他们实际上可能不希望你想使用是处理这个意图的应用程序的应用

This isn't really a valid situation. How would you make sure the user has the Open Source app installed? What you have now is technically the correct way to do it since you have no control what applications they have installed - and they may in fact NOT want the application you want to use be the application to handle the intent.

这篇关于致电或启动外部应用程序的Andr​​oid的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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