# Setup Custom Lookup For SharinPix Form In Progress

## Overview

In this article, we will demonstrate how to setup the SharinPix Form In Progress Sync. To do so we will:

1. [Create a lookup relationship field on the SharinPix Form In Progress object](#step-1-creation-of-a-lookup-relationship-field-on-sharinpix-form-in-progress)
2. [Configure the SharinPix Form In Progress Setting custom metadata](#step-2-configure-the-custom-metadata)

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

* The **SharinPix Form In Progress Sync Setting** works alongside the **SharinPix Form** featur&#x65;**.** Therefore, ensure that the **SharinPix Form** feature has been configured properly before configuring this Sync Setting. For more information on how to configure **SharinPix Form** , please refer to the following article: [SharinPix Form](https://docs.sharinpix.com/forms/overview-and-getting-started/sharinpix-forms)
* The latest SharinPix Package version: [*How to upgrade SharinPix package*](https://app.gitbook.com/s/i8tH1o5AHthxksYgF6ij/how-to-update-sharinpix-package-from-the-appexchange)
* The **SharinPix Forms Admin** or **SharinPix Forms User** permission set should be assigned to all users to ensure they have the right to create, edit, and delete the **SharinPix Form In Progress** record through the SharinPix Form In Progress Sync Setting. For more information on these two permission sets, check [SharinPix Permission Set](https://app.gitbook.com/s/5EvYRrLbUyvRh8o1jmMG/access-and-security/sharinpix-permission-sets)
  {% endhint %}

## Step 1: Creation of a Lookup Relationship Field on SharinPix Form In Progress

Depending on the Object you want to use SharinPix Form In Progress Sync on, you must create a lookup relationship field on the SharinPix Form In Progress Object that links to the parent object. This demo will use the **SharinPix Visit** object.

Follow the steps below:

* Go to **Setup, then access Object Manager**
* Type form in the search bar, press Enter, and click **SharinPix Form In Progress**
* On the left menu, click on **Fields and Relationships,** and then click on **New**

For the new field:

* Select **Lookup Relationship** as **Data Type** then click **Next**
* For the field **Related To**, select **SharinPix Visit** then click **Next**

![](https://2647402409-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrRD1Xcn9HtKcyfQ9Ghyk%2Fuploads%2Fgit-blob-2c052e54c4c89e580080efb54d410beefbcb937b%2FDOC%20SF%20-%201920%20x%20360.png?alt=media)

* On the next page, the field **Field Label** will be auto-populated
* Enter a **Field Name;** as an example **Visit\_Lookup\_\_c**
* Leave the other fields as default

<figure><img src="https://2647402409-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrRD1Xcn9HtKcyfQ9Ghyk%2Fuploads%2FCs9J0QyyEiB8X7mfEevC%2Fformimg4.png?alt=media&#x26;token=bf78f7ee-6451-4ae2-b7fe-12aaf482af8a" alt=""><figcaption></figcaption></figure>

* Proceed to the next steps and finally save the new relationship.

When you take a look back at the **Fields & Relationships** section, you should see the new relationship displayed as shown in the figure below.

<figure><img src="https://2647402409-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrRD1Xcn9HtKcyfQ9Ghyk%2Fuploads%2Fe8boLH6d5aPCm9nGvQQp%2Fformimg5.png?alt=media&#x26;token=c4bf728f-1ef5-425c-a990-d8b02f57593c" alt=""><figcaption></figcaption></figure>

* Copy the field name: **Visit\_Lookup\_\_c** as we will need this in our next step.

{% hint style="warning" %}
**Warning:**&#x20;

Ensure that you provide at least read access to the lookup field (**Visit\_Lookup\_\_c** in this case) for all users viewing/creating SharinPix Form Response records.
{% endhint %}

## Step 2: Configure the Custom Metadata

This section demonstrates how to configure the SharinPix Form In Progress Setting custom metadata.

To do so, follow the steps below:

* Go to **Setup** and type metadata, then click on **Custom Metadata Types**
* Select the **Manage Records** action next to the label **SharinPix Form In Progress Setting**

<figure><img src="https://2647402409-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrRD1Xcn9HtKcyfQ9Ghyk%2Fuploads%2FEfDcRiuelIxQGkCkp0FB%2Fformimg6.png?alt=media&#x26;token=0f95422c-c01f-4353-b1f8-2e85f9fe02c4" alt=""><figcaption></figcaption></figure>

* Create a new record.
* For the field **Label**, as an example, enter **Form Sync on Visit**
* The field **SharinPix Form In Progress Setting Name** is auto-populated when clicking anywhere outside the text box.
* For the field **Parent Object Name**, enter the **object API name;** in our case it is **sharinpix\_\_Visit\_\_c**
* For the field **Parent Field Name**, enter the field name of the lookup relationship field created in the previous section, that is **Visit\_Lookup\_\_c** ( Remember the field name we asked you to copy? You can now paste it here )
* Click **Save** when done.

![](https://2647402409-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrRD1Xcn9HtKcyfQ9Ghyk%2Fuploads%2Fgit-blob-a4ade16add003e6be50098227084a4f244a166a0%2FDOC%20SF%20-%201920%20x%201080%20\(2\).png?alt=media)

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

You should be careful when entering values for the fields **Parent Object Name** and **Parent Field Name**.

* The field **Parent Object Name** refers to the object's API Name. In case you are using a custom object, you should ensure that the API name is correctly entered. For example, if you are using a custom object named **My Custom Object**, the value to be entered for the field **Parent Object Name** will be **My\_Custom\_Object\_\_c**.
* The field **Parent Field Name** on the other hand refers to the field name of the lookup relationship. You should ensure that the value entered for the field **Parent Field Name** matches the corresponding field name value in the lookup relationship.&#x20;
  {% endhint %}
