Some test text!

menu
search

Get started with Cordova

This guide will help you integrate a free trial of the PDFTron Native Plugin for Android applications using Cordova. Your free trial includes unlimited trial usage and support from solution engineers.

See here for the get started guide for using the PDFTron Cordova Native Plugin on Android.

Note: There are other approaches that can be used to integrate PDFTron technology with Cordova. Please see this FAQ page to find out more about the relative strengths of each approach.

linkPrerequisites

linkSetup

If you don't already have a Cordova codebase, start one. If you do, then make sure iOS is added as a platform and skip to integration.

  1. Create a new Cordova project called pdfhello

    cordova create pdfhello com.example.pdf pdfhello
    
    cd pdfhello
  2. Add iOS as a platform to build the Cordova application for.

    cordova platform add ios

linkIntegrate PDFTron Native Plugin into your Cordova Application

  1. Add the pdftron-cordova plugin in your project directory.

    cordova plugin add https://github.com:PDFTron/pdftron-cordova.git
  2. From your PDFNet.dmg download, copy the /Lib/ folder into pdfhello/platforms/ios/pdfhello/

  3. Open the project in Xcode. You can do this by double-clicking the pdfhello/platforms/ios/pdfhello.xcodeproj file.

  4. Select the project in the left pane and go to the General tab. Scroll down to find the Embedded Binaries section. Here, add Lib/Tools/Tools.framework and Lib/Framework-dynamic.PDFNet.framework from the Lib/ folder you copied into your project. You can do this by dragging them in from Finder or by clicking the + sign to browse your files.

    General Add Frameworks
  5. Go to the Build Phases tab and click on the + button to add a New Run Script Phase. Copy and paste the following into the shell command:

    bash "$BUILD_PRODUCTS_DIR/$FRAMEWORKS_FOLDER_PATH/PDFNet.framework/strip-framework.sh"

    This will ensure invalid slices are striped from the framework before being submitted to the app store (a longstanding Xcode bug).

    Build Phases Add Script

linkNext step

View a document

Get the answers you need: Support

close

Free Trial

Get unlimited trial usage of PDFTron SDK to bring accurate, reliable, and fast document processing capabilities to any application or workflow.

Select a platform to get started with your free trial.

Unlimited usage. No email address required.

PDFTron Receives USD$71 Million Growth Investment Led By Silversmith Capital Partners

Learn more
close