---
schema_version: "1"
id: 181338c6a00ab2851fd5960fa4bf6cde0f120a9233869a6520c3f8a10be0a78f
title: Close a Flexcard Flyout Modal from an Action (Managed Package)
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/xcloud/264-0-0/os_close_a_flexcard_flyout_modal_from_an_action.md
canonical_url: https://help.salesforce.com/s/articleView?id=xcloud.os_close_a_flexcard_flyout_modal_from_an_action.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 98cf2ac11c9c382e7e93f15152b6c3eb350a207712dc3835c5e64389234cfec5
description: For the managed package runtime, enable users to close a Flyout from an actionable element inside the modal. Add a custom event action with the closemodal event to your child Flexcard, custom LWC, or Omniscript flyout.
products:
  - Omnistudio
release: "264"
---
# Close a Flexcard Flyout Modal from an Action (Managed Package)

For the managed package runtime, enable users to close a Flyout from an actionable element inside the modal. Add a custom event action with the `closemodal` event to your child Flexcard, custom LWC, or Omniscript flyout.

![Managed Package app icon](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-xcloud-omnistudio_for_managed_packages-264-0-0-production-enus/aa2554ec-624a-4ee6-8da4-6435670e6e62/resources-global/_corporate/images/managedpackageicon.png) This information is for Omnistudio for Managed Packages. For Omnistudio on standard runtime, see [Omnistudio Help](https://help.salesforce.com/s/articleView?id=xcloud.os_omnistudio_standard.htm&language=en_US).

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small ">
        <colgroup>
          <col>
        </colgroup>
        <thead class="slds-text-title_caps ">
          <tr class="">
            <th scope="col" class="slds-cell-wrap" style="vertical-align:top;" id="d309116e49">
              <p style="margin-bottom:0;">Required Versions</p>
            </th>
          </tr>
        </thead>
        <tbody>
          <tr class="">
            <td data-label="Required Versions" class="slds-cell-wrap" style="vertical-align:top;" headers="d309116e49 ">
              <p style="margin-bottom:0;">Available beginning Spring '22.</p>
            </td>

          </tr>
        </tbody>
      </table>

1. Open or create the Flexcard that displays the action that closes the modal. For example, if your flyout is an Omniscript, select the Flexcard that is embedded in the Omniscript. If your flyout is a child or custom LWC Flexcard, select it.
2. Drag an actionable element such as an Action or Block onto the canvas. Click **\+ Add Action** if your element is not an Action element to display action properties.
3. Select Event as the **Action Type** and Custom as the **Event Type**.
4. Enter closemodal in the **Event Name** field.
5. Select both **Composed** and **Bubbles**.
6. For additional configuration options for your custom event action, see [Trigger a Custom Event from an Action on a Flexcard (Managed Package)](https://help.salesforce.com/s/articleView?id=xcloud.os_trigger_a_custom_event_from_an_action_on_a_flexcard.htm&release=264.0.0&type=5 "For the managed package runtime, notify a Flexcard of an event occurring from an action on an element. Then execute an action based on the event. Custom Events are used to communicate between a child to its parent, whether it's between a child Flexcard and its parent, or between an element and the Flexcard it's on.").
7. Open or create a Flexcard that displays the flyout.
8. Drag an action (or actionable element such as a Block) onto the canvas and select Flyout as the **Action Type**.
9. From the **Flyout Type** dropdown, select the type of content to display in the modal.
10. Click into **Flyout** and select from the list of active child Flexcards, Custom LWCs or Omniscripts to display in your modal.
11. Select Modal from the **Open Flyout In** dropdown.
12. To configure other flyout action properties, see [Launch a Flyout from an Action on a Flexcard (Managed Package)](https://help.salesforce.com/s/articleView?id=xcloud.os_launch_a_flyout_from_an_action_on_a_flexcard.htm&release=264.0.0&type=5 "For the managed package runtime, create a flyout to display additional information when a user clicks an action on a Flexcard. For example, a Flexcard that displays Account information can display the Primary Contact's name and email address in a flyout.").
13. To test closing the modal, open the Flexcard with the flyout action created in Step 7 and click the **Preview** tab. Click on the action that launches the flyout modal, and click the action element inside the modal to close the modal.