> For the complete documentation index, see [llms.txt](https://support.pears.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://support.pears.io/plan/community-events/link-a-program-activity-to-an-event.md).

# Link a Program Activity to an Event

Learn how to create a program activity from a community event in PEARS, link an existing program activity to an event, and unlink it.

Events are usually promoted before the direct education they deliver is reported. From a community event, you can create a program activity that starts with the event's details, or link a program activity that already exists. Each event can be linked to one program activity, and each program activity to one event. Once they are linked, each record shows the other, and the program activity's Demographics page can auto-calculate participant demographics from the event's registrations.

You can also link the two records from the program activity. See [Link an Event to a Program Activity](https://support.pears.io/engage/program-activities/link-an-event-to-a-program-activity.md) and [Create an Event from a Program Activity](https://support.pears.io/engage/program-activities/create-an-event-from-a-program-activity.md).

## Before You Begin

* Your organization must have the Program Activities module turned on. This is the **Use Program Activities Module** setting in [Organization Settings](https://support.pears.io/administration/administration/organization-settings.md).
* You need a Program Activities permission. Without it, the **Program Activity** card does not appear on the event until a program activity is linked.
* You must be able to view the event: as its creator, as one of its [collaborators](https://support.pears.io/plan/community-events/collaborators.md) with either access level, or through your role. You do not need edit access to the event.
* The event must not be canceled. A canceled event keeps the program activity it is linked to, but it cannot be linked or unlinked.

## The Program Activity Card

The **Program Activity** card appears in the right column of the event's detail page and its section pages, below the **Progress** panel. While no program activity is linked, it offers two buttons:

* **Create Program Activity** — creates a new program activity that starts with this event's details. The button appears only if you have permission to add program activities.
* **Link Existing** — links a program activity that already exists.

## Create a Program Activity from an Event

{% stepper %}
{% step %}

#### Open the Event

From the PEARS homepage, hover over the **Plan** menu in the top navigation bar and click **Community Events**. Click the event to open its detail page.
{% endstep %}

{% step %}

#### Click Create Program Activity

On the **Program Activity** card, click **Create Program Activity**. The **Create Program Activity** dialog box lists the details that will be copied from the event: **Name**, **Program Areas**, **Unit**, **Site**, **Delivery Method**, **Sessions**, and **Collaborators**. See [What PEARS Copies to the Program Activity](#what-pears-copies-to-the-program-activity).
{% endstep %}

{% step %}

#### Click Create and Open

Click **Create and Open**. The program activity form opens with the event's details filled in, and a message at the top explains that saving links the new program activity to the event. Nothing is saved yet.
{% endstep %}

{% step %}

#### Complete the Required Fields

Fill in the required fields the event cannot supply, such as **Action plans**, and check the values that were copied. See [Create a Program Activity](https://support.pears.io/engage/program-activities/create-a-program-activity.md) for each field.
{% endstep %}

{% step %}

#### Save the Program Activity

Click **Save and continue** or **Save**. PEARS creates the program activity, links it to the event, and adds the event's collaborators to it. **Save and continue** takes you to the program activity's Collaborators page.
{% endstep %}
{% endstepper %}

### What PEARS Copies to the Program Activity

The new program activity starts with the following information from the event:

* **Program activity name** — the event's name.
* **Program areas** — the event's program areas, when your organization uses program areas. Only program areas that your organization's current reporting periods offer for program activities are copied; select any others yourself.
* **Unit** — the event's unit.
* **Delivery Site** — the event's site.
* **Methods used to deliver this program** — **In person** when the event is in-person, **Virtual, live online** when it is virtual, or both. These are filled in only for reporting periods in 2023 and later.
* **Sessions** — one session for each [event session](https://support.pears.io/plan/community-events/event-sessions.md), with its start date, start time, and length. An event with no sessions becomes a single session at the event's start date and time, with the event's length. Dates and times follow the event's time zone. A length outside the 1 to 1,439 minutes the session form accepts, such as a multi-day event's, is left blank for you to enter.
* **Collaborators** — the event's collaborators who are active PEARS users with Program Activities permissions, with the same access and contributor details. They are added when you save, and each one receives the usual email for being added as a collaborator.

Demographics are not copied. After the program activity is saved, use **Auto Calculate** on its Demographics page to fill them in from the event's registrations. See [Calculate Demographics from Event Registrations](https://support.pears.io/engage/program-activities/link-an-event-to-a-program-activity.md#calculate-demographics-from-event-registrations).

## Link an Existing Program Activity

{% stepper %}
{% step %}

#### Open the Event

From the PEARS homepage, hover over the **Plan** menu in the top navigation bar and click **Community Events**. Click the event to open its detail page.
{% endstep %}

{% step %}

#### Click Link Existing

On the **Program Activity** card, click **Link Existing**. The **Link Existing Program Activity** dialog box appears.
{% endstep %}

{% step %}

#### Select the Program Activity

In the **Program Activity** field, type part of the program activity's name or its ID and select it from the matching options. Each option shows the program activity's ID, unit, and first session date. The search tolerates small typos.

When you select a program activity, its details appear below the field (name, ID, program areas, unit, site, delivery method, and sessions) so you can check that it is the right one before linking.

{% hint style="info" %}
**TIP:** The list shows only program activities in your organization that you can edit, that are not linked to another event, that are not marked as complete, and that are not in a closed reporting period (unless you have permission to edit past reporting period data). If a program activity you expect is missing, check whether it is already linked elsewhere or marked as complete.
{% endhint %}
{% endstep %}

{% step %}

#### Click Link Program Activity

Click **Link Program Activity**. The link is saved immediately; there is no separate Save step. Linking does not change any fields on the program activity. PEARS confirms that the program activity was linked, and the card now shows it.
{% endstep %}
{% endstepper %}

## After You Link a Program Activity

The **Program Activity** card shows the linked program activity's name, its ID, whether it is **In Progress** or **Complete**, and the number of sessions with their date range. The card offers two actions:

* **View Program Activity** — opens the program activity's detail page in a new tab.
* **Unlink** — removes the link. See [Unlink a Program Activity](#unlink-a-program-activity).

If you cannot view the linked program activity, the card shows only its name and ID, with the message **You don't have access to view this Program Activity.** in place of the **View Program Activity** button.

## Unlink a Program Activity

To remove the link, click **Unlink** on the **Program Activity** card. The **Unlink Program Activity** dialog box asks you to confirm; click **Unlink**. PEARS confirms that the program activity was unlinked, and the card shows its **Create Program Activity** and **Link Existing** buttons again.

Unlinking only removes the connection between the two records. Neither record is deleted, and demographics already calculated on the program activity are kept, but the program activity can no longer auto-calculate demographics from this event.

{% hint style="warning" %}
**NOTE:** The **Unlink** button appears only when you can edit the linked program activity and it is not complete or in a closed reporting period. To unlink a completed program activity, mark it as incomplete first. See [Mark a Program Activity as Complete](https://support.pears.io/engage/program-activities/mark-a-program-activity-as-complete.md#mark-as-incomplete).
{% endhint %}
