【问题标题】:How to render the pdf file in web view using android application?如何使用 android 应用程序在 web 视图中呈现 pdf 文件?
【发布时间】:2014-12-15 10:29:34
【问题描述】:

我正在开发与网络服务相关的移动应用程序。当我们在默认浏览器中调用以下服务 url 时,将下载 pdf 文件。

服务网址:http://demo.com/microeforms/Pages/MicroeForms/Student/StudentProgressReports/StudentReport.aspx?Source=mobileapp&StudentCode=12/0429&AcademicYearId=751&AcademicYearText=2014 - 2015&StudentLevelId=151&StudentLevelText=Y1&StudentGroupId=562&StudentGroupText=1A&BranchId=100&BranchName=PS02-TEPS&Term=1

输出:学生进度报告.pdf

但我必须在移动浏览器中调用此服务 URL 请告诉我如何在移动应用程序中调用此服务 URL 以及如何在 Web 视图中显示下载的 pdf 文件?

【问题讨论】:

  • 大家好,错误已修复,非常感谢您分享信息。

标签: android web-services pdf


【解决方案1】:

像这样尝试。

Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("http://naseformsdemo.agilitylogistics.com/microeforms/Pages/MicroeForms/Student/StudentProgressReports/StudentReport.aspx?Source=mobileapp&StudentCode=12/0429&AcademicYearId=751&AcademicYearText=2014 - "));
startActivity(browserIntent);

【讨论】:

  • 我正在使用文件下载器的概念,它工作得很好,谢谢 Giridharan。
猜你喜欢
  • 2014-07-24
  • 2022-11-26
  • 1970-01-01
  • 1970-01-01
  • 2019-11-20
  • 2014-01-03
  • 1970-01-01
  • 2020-09-21
  • 1970-01-01
相关资源
最近更新 更多