Kotlin PDF viewer example for Android

Launch the default Kotlin-based PDF viewer UI and effortlessly load a PDF document in a web browser using Nutrient Android SDK’s PDF viewer library. Access code samples, step-by-step resources, and implementation guides for seamless PDF viewing and integration on Android.


/*
* Copyright © 2023-2025 PSPDFKit GmbH. All rights reserved.
*
* The PSPDFKit Sample applications are licensed with a modified BSD license.
* Please see License for details. This notice may not be removed from this file.
*/
package com.pspdfkit.catalog.examples.kotlin
import android.content.Context
import com.pspdfkit.catalog.R
import com.pspdfkit.ui.PdfActivity
/**
* Opens the [PdfActivity] for viewing a PDF stored within the app's asset folder.
*/
class DefaultExample(context: Context) : AssetExample(context, R.string.defaultExampleTitle, R.string.defaultExampleDescription)

This code sample is an example that illustrates how to use our SDK. Please adapt it to your specific use case.