> For the complete documentation index, see [llms.txt](https://docs.apryse.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.apryse.com/xamarin/learn-more/java-android.md).

# Create Tools package from PDFViewCtrlTools Java source code

Learn how to build the PDFViewCtrlTools package for Xamarin.Android from source code. Follow this comprehensive tutorial to customize UI controls and tools, creating a NuGet package. Requires the late

{% hint style="info" %}
**This tutorial only applies to Xamarin.Android.**
{% endhint %}

{% hint style="info" %}
**Why do I want to build Tools package from source?**

`PDFViewCtrlTools` project for Android is an open source java project. Although a number of UI controls and tools are provided out-of-the-box, there may be behavior that you would want to change to best suit your own project. The best way to do so will be diving into the source code.
{% endhint %}

Before you get started, it is a good idea to first have some basic knowledge on the topic. Xamarin provides a comprehensive guide on [Binding a Java Library](https://developer.xamarin.com/guides/android/advanced_topics/binding-a-java-library/) and we recommend you to briefly go through it. Please note that you will not need to create a binding project as it is already provided in the package.

Apryse Android SDK for Xamarin is a completely open source binding project. By the end of this tutorial, you will be able to create `PDFTron.Android.Tools` NuGet package from source.

{% hint style="info" %}
**Latest Visual Studio is required to proceed.**
{% endhint %}

{% hint style="info" %}
**Windows machine: Due to character limit on Windows machine, it is recommended that you unzip the packages with short root path. For example, D:\MyFolder will be a good path but D:\MyFolder\PDFTronXamarinAndroid\MyLongLongLongLongLongLongLongLongPath will be a bad path.**
{% endhint %}

1. Download the [Apryse for Xamarin.Android SDK package](/xamarin/get-started/xamarin-android/integrate-android.md), refer to as `PDFNetXamarin.Android` package below
2. Download the [Apryse for Android SDK package](/android/get-started/get-started.md), refer to as `PDFNetAndroid` package below
3. In `PDFNetAndroid` package, update the `/lib/src/PDFViewCtrlTools` project in Android Studio as you wish
4. Once you are done with changing the source code in Java, create `PDFViewCtrlTools-release.aar` by either clean build from Android Studio or command line via `gradle clean build`, the output can be found in `/PDFViewCtrlTools/build/outputs/aar` folder
5. Rename `PDFViewCtrlTools-release.aar` from previous step to `tools.aar` and copy it to `PDFNetXamarin.Android/lib/android/Native` folder
6. Copy either of `full/pdftron.aar` or `standard/pdftron.aar` from `PDFNetAndroid/lib` folder to `PDFNetXamarin.Android/lib/android/Native` folder, your `PDFNetXamarin.Android/lib/android/Native` folder should now look like this:

![](https://653871032-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FgjsBtuYmcKhWOdM9VCg4%2Fuploads%2Fgit-blob-222029305f7a884b03b2b44bc63f21bb40ec89d0%2F7a8bde7e09c44ede7bd60ad09d90814b6c2b7c39-268x263.png?alt=media)

1. From `PDFNetXamarin.Android` package, open `/projectSrc/PDFNetAndroidXamarin/PDFNetAndroidXamarin.sln` in Visual Studio, make sure you see it gets all the NuGet Packages
2. Make sure there is no missing files when you expand the folders in Visual Studio

![](https://653871032-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FgjsBtuYmcKhWOdM9VCg4%2Fuploads%2Fgit-blob-8fb31b81a841344fa7fb0c30abf68954f05597df%2Fed88ab288fbb73970e185f4517cdf1261a40d836-288x547.png?alt=media)

1. Clean the project
2. Build `PDFViewCtrlTools` project
3. You can find the output `PDFTron.Android.Tools.nupkg` in `PDFNetXamarin.Android/lib/android` folder


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.apryse.com/xamarin/learn-more/java-android.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
