# SharinPix Rich Text To PDF

{% hint style="warning" %}
This component is only available in the Enterprise license plan of SharinPix. For more info, please contact <support@sharinpix.com>
{% endhint %}

{% hint style="info" %}
The **SharinPix Rich Text To PDF** component permits the conversion of images found inside a **Rich Text** field into a PDF.

This is a great way for you to generate report and send them as attachment in email. In addition, the PDF generated will be saved on the record as Content Document.
{% endhint %}

<figure><img src="https://2221230591-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5EvYRrLbUyvRh8o1jmMG%2Fuploads%2Fgit-blob-3ccfad31a4669b6dc3c3a46d539e0fe2d9a5380d%2Fimage%20(12).png?alt=media" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
**Information:**

This feature is only available on Lightning. It can be used on:

* Page Builder
* Desktop
* Mobile
* In your own Lightning Component development
  {% endhint %}

## Getting Started

{% hint style="warning" %}
**Note:**

In order to use the SharinPix Rich Text To PDF component you should ensure that:

* Your record page should have **at least one** field of type **Text Area (Rich)**.
* The permission set **SharinPix Lightning Components** is assigned to all users attempting to use the SharinPix Rich Text To PDF component.
  {% endhint %}

To use the SharinPix Rich Text To PDF component, you simply need to drag and drop the component from the Lightning App Builder onto your page layout.

<figure><img src="https://2221230591-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5EvYRrLbUyvRh8o1jmMG%2Fuploads%2Fgit-blob-ee5d6e60c8fb7b78feee7b068868df19df548a39%2Fimage%20(1)%20(3).png?alt=media" alt=""><figcaption></figcaption></figure>

## Lightning Component Parameters

<figure><img src="https://2221230591-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5EvYRrLbUyvRh8o1jmMG%2Fuploads%2Fgit-blob-d56327bd4c6c5fa4f671e8f4a1ad82b787c36895%2FImage%20from%20Gradio%20(13).png?alt=media" alt=""><figcaption></figcaption></figure>

* **Generate PDF Button Label:** Used to specify the button's label.
* **Rich Text field:** Used to specify the API name of the Rich Text field whose content will be converted to PDF.

## Demo

The example below shows a Rich Text field containing images:

![](https://2221230591-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5EvYRrLbUyvRh8o1jmMG%2Fuploads%2Fgit-blob-b0d4f11a9e9d177bf47b3ee0b06504092f60f592%2Fimage%20\(2\)%20\(3\).png?alt=media)

To generate the PDF click on the SharinPix Rich Text To PDF component's button. The picture below depicts a preview of the PDF generated:

![](https://2221230591-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F5EvYRrLbUyvRh8o1jmMG%2Fuploads%2Fgit-blob-f2567014979b0fa4515b25878b79b8f8bde41655%2Fscreenshot-sharinpix-fsl-demo-dev-ed.lightning.force.com-2020.05.18-16_15_34%20\(1\)%20\(1\).png?alt=media)
