-1

how to read the pdf filein android using xml pull parser from server and view the content in pdf formate...this is the xml file

<id>1</id>
        <class>Std-1</class>
        <subject>English</subject>
        <releasedate>2012-02-22T13:56:28Z</releasedate>
        <image>http://msnapi.cricbuzz.com/flags/team_12_100.png</image>
    <downloadurl>http://www.poemhunter.com/i/ebooks/pdf/henrik_wergeland_2012_6.pdf</downloadurl>

</std>
user1398452
  • 7
  • 1
  • 3

1 Answers1

1

Once you have received the XML data, parse it to retrieve the URL for the PDF.

Make an http connection to download the PDF. Once downloaded you can open it in 2 different ways.

  1. Let the system take care of it so that any application that handles that mime type can open it but that means that you assume that there is a PDF reader.
  2. Use a PDF library pragmatically to read the PDF.

This SO Post has links to some PDF libs.

This one has reference to another one

Community
  • 1
  • 1
Orlymee
  • 2,349
  • 1
  • 22
  • 24