Some test text!

Loading...
Guides
PDF to WORD

Convert PDF to WORD in Android

Internet connection is required for this feature.
Additional easyPDF Cloud REST API plan required.
PDF to Word

The PDF to WORD conversion API uses easyPDF Cloud REST API and allows conversion from PDF to WORD and PDF to HTML.

Integration

Integrate actions package with Gradle

  1. Integrate PDFTron core and the tools library as described here .

  2. In your app module's build.gradle file (usually app/build.gradle), add the dependency for PDFTron's actions package:

//@data {"ga":1716166800}// dependencies { implementation "com.pdftron:actions://variable android-sdk-ver//" } ```

Integrate actions package manually

  1. Integrate PDFTron core and tools packages as described here .

  2. Copy pdftron-actions.aar directly into your app module's libs directory. You will see other PDFTron AARs here such as pdftron.aar and tools.aar

  3. In your app module's build.gradle file (usually app/build.gradle), add a dependency to PDFTron actions package:

//@data {"ga":7044066600}// dependencies { implementation "com.pdftron:collab@aar"

implementation "com.squareup.okhttp3:okhttp:3.12.8"
}
```

Initialize

First, initialize EasyPdfService:

// Client ID. You can get your client ID from the developer page
// (for registered user, you must sign in before visiting this page)
// https://www.easypdfcloud.com/developer
//
// To test the sample code quickly for demo purpose, you can use
// the following demo client ID:
//
//   1eb210be402844c287b4464026eb89cb
//
private final String clientId = "1eb210be402844c287b4464026eb89cb";

// Client secret. You can get your client secret from the developer page
// (for registered user, you must sign in before visiting this page)
// https://www.easypdfcloud.com/developer
//
// To test the sample code quickly for demo purpose, you can use
// the following demo client secret:
//
//   335F8FC64EC58B460E1420B1EE6B253DEB81EAA09936DEAFF3B14350B5EC8558
//
private final String clientSecret = "335F8FC64EC58B460E1420B1EE6B253DEB81EAA09936DEAFF3B14350B5EC8558";

// Workflow ID. You can get your workflow ID from the developer page
// (for registered user, you must sign in before visiting this page)
// https://www.easypdfcloud.com/developer
//
// To test the sample code quickly for demo purpose, you can use
// the following demo workflow ID:
//
//  0000000000000001 : "Convert PDF to Word" workflow
//
private final String workflowId = "0000000000000001";

EasyPdfService.initialize(clientId, clientSecret);
EasyPdfService.setJobId(EasyPdfService.Type.PDF_TO_WORD, workflowId);

Convert

Then perform the conversion:

private CompositeDisposable mDisposables = new CompositeDisposable();

private void export(File inputFile, File ouputFolder) {
    mDisposables.add(EasyPdfService.startPdf2WordJob(inputFile, ouputFolder)
            .subscribe(s -> {
                // do something with the converted file
            }, throwable -> {
                // handle error
            }));
}

Get the answers you need: Support