How to add PDFViewCtrl view dynamically without using layout file?


Product Version:Latest

Please give a brief summary of your issue:How to add PDFViewCtrl view dynamically without using layout file?
(Think of this as an email subject)

Please describe your issue and provide steps to reproduce it:
(The more descriptive your answer, the faster we are able to help you)
I want to create PDFViewCtrl view programatically without using XML layout. How could i achieve this.

I have tried, but got below error.
No implementation found for long com.pdftron.pdf.Rect.RectCreate(double, double, double, double)


val pdfViewCtrl = PDFViewCtrl(context,null)

Thank you.
Please provide a link to a minimal sample where the issue is reproducible:

Hello, I’m Ron, an automated tech support bot :robot:

While you wait for one of our customer support representatives to get back to you, please check out some of these documentation pages:


Hi Manoj, from the error it sounds like you have not initialized PDFTron library.

You can add your license like the following in your application’s manifest XML:

<!-- Add license key in meta-data tag here. This should be inside the application tag. -->
    <meta-data android:name="pdftron_license_key" android:value="YOUR_KEY"/>

Read more here: