机器人:从我的应用程序使用内置的PDF查看器打开PDF

机器人:从我的应用程序使用内置的PDF查看器打开PDF

问题描述:

这是我原来的问题:

我希望能够打开PDF文件   使用内置在Android我的应用程序   PDF阅读器应用程序,但我不知道如何   启动其他应用程序。我敢肯定,我要   调用start活动,我只是不知道   如何识别应用程序IM开   如何将文件传递给该特定   应用程序。

I want to be able to open a pdf file in my app using the android's built in pdf viewer app, but i dont know how to start other apps. I'm sure i have to call start activity, i just dont know how to identify the app im opening and how to pass the file to that specific app.

任何人都有一个线索吗?

Anyone have a clue?

我刚刚获悉,PDF阅读器,我有我的电话实际上是由HTC和已安装Adobe作出刚好发布了他们的Andr​​oid PDF阅读器(这是伟大的)。因此,新的问题是:我如何验证用户是否已经安装了Adobe的浏览器,然后我如何从我的应用程序打开该应用程序文件

I just learned that the pdf viewer i have on my phone is actually made by HTC and that Adobe just barely released their android pdf viewer (which is great). So the new question is this: how do i verify that the user has installed adobe's viewer, and then how do i open the file in that app from my app?

AFAIK,Adobe已经没有记录任何公开的意图,它希望开发者使用。

AFAIK, Adobe has not documented any public Intents it wants developers to use.

您可以尝试使用 ACTION_VIEW 意图乌里指向文件(无论是在SD卡上,或 MODE_WORLD_READABLE 在您的应用程序 - 本地文件存储)和MIME类型应用程序/ PDF格式的

You can try an ACTION_VIEW Intent with a Uri pointing to the file (either on the SD card or MODE_WORLD_READABLE in your app-local file store) and a MIME type of "application/pdf".