Viewing PDF in Adobe AIR on Android etc.

Skip to first unread message


May 7, 2013, 2:40:27 PM5/7/13


I ran across PDFTron SDKs and was wondering if you have tried using it within a AIR ANE? AIR apps for mobile don't really have a good solution for viewing pdfs, especially on Android, so I was wondering if your solution could do this.


For viewing PDFs, there are couple of options:
a) native route via PDFNet Mobile SDKs (
b) browser based viewing (HTML+JS / Flash / Silverlight ) via WebViewer (
With option a) you could use native SDK either directly as part of native Android/iOS/WinRT/WP8/... app our you can try to access the native library via Native Extensions for Air (ANE). The last time we tried Native Extensions for Air we found that interop suffered from some limitations (e.g. related to exception handling etc.), but these may have beed addressed in recent updates from Adobe.
The second option is WebViewer (you could use either Flash or HTML/JS clinet). This solution might be simpler on the application side, however it will not load a PDF file directly. Instead you need to first convert the PDF to a XOD file (which is a web optimized XPS file). There are three ways to do this, see the link below for details. Note, that though it's called WebViewer, the Flash version is capable of loading local XOD files, and it can load while the PDF is being converted to XOD. For more info please see:,,

Please keep in mind that if you use HTML5 WebViewer you would not necessarily need to use Flash at all (althoug you could if you really want to stick with Flash/AIR). Instead you can just write the app in JS+HTML. You can either write a browser based app or you can create minimal native (e.g. android, ios, ...) app with embedded browser control (i.e. WebView), which loads WebViewer. For a concrete example, please take a look at Android sample project ( see ‘WebViewer\samples\android’) that comes along the latest WebViewer Beta package ( ).
Note: Both HTML5 and Flash viewers come with local part retrievers that will allow you read local files (WebViewer\samples\android\src\com\pdftron\webviewer\ in online or offline mode.

Reply all
Reply to author
0 new messages