2

Web サーバーに pdf ファイルがあります。次からアクセスできます。

http://ドメイン名/files/test.pdf

モバイル デバイスのデフォルトの PDF ブラウザ (存在する場合) からこの PDF ファイルを開く関数を呼び出す方法はありますか?

前もって感謝します。

注: j2me アプリケーションから pdf ファイルを解析して表示することを求めているわけではありません。

注 2:私が知る限り、ありません...しかし、メールに添付されている場合、blackberry デバイスは pdf ファイルを開くことができると思います。

編集:

もし可能ならば:

私が必要としているのは、Web サーバーでホストされている PDF ファイルをモバイル デバイスから開くことです。私はpdfブラウザを書きたくありません。ミッドレット (Java ME) が必要です。モバイル デバイスがデフォルトの PDF ビューアーで PDF を開くようにします。

これは、C# アプリケーションの作成に似ています。

Process process = new Process();
process.StartInfo.FileName = "explorer.exe";
process.StartInfo.Arguments = "http://domain-name.com/files/test.pdf";
process.Start();
4

2 に答える 2

4

Well, first things first.

What happens on your mobile phone what you open the "http://domain-name/files/test.pdf" url?

Presumably, either your web browser downloads the file (and maybe asks if you want to open it afterwards) or your web browser and pdf reader are sufficiently integrated together that the pdf file is automatically displayed.

You can very probably mimic that behaviour from a J2ME application by using:
javax.microedition.midlet.MIDlet.platformRequest("http://domain-name/files/test.pdf");

If that's not good enough but your phone is clever enough (I don't know of any that clever yet), you may be able to use JSR-211 to discover a pdf-reading content handler.

于 2009-11-12T14:07:43.327 に答える
0

いいえ、j2me で PDF を開くことはできません。ごめん。

于 2009-11-12T08:21:13.283 に答える