This documentation supports the 20.08 version of BMC Helix Platform. 
To view an earlier version, select 20.02 from the Product version menu.

Displaying images from attachments at runtime

As a developer or an application business analyst, you can configure a view definition to display images from attachments. The images are displayed in the application.

Use the Image view component to display an image stored in an attachment field. For example, you can display an avatar stored in an attachment field.

Important

Application business analysts can customize the objects developed in their own applications and that are marked customizable by the developers. However, they cannot customize the objects developed in com.bmc.arsys.

For example, you cannot customize objects in core BMC applications like Foundation, Approval, and Assignment.

Before you begin

Make sure that you have created an attachment field in the record definition. 

To learn more about adding attachment fields, see Creating or modifying regular record definitions.

To add an image view component to a view definition

  1. Log in to BMC Helix Innovation Studio and navigate to the Workspace tab.
  2. Select the application to which you want to add the Image view component. 
  3. On the Views tab, click the name of the view definition to which you want to add the Image view component.
  4. From Palette, drag the Image view component to the canvas.
  5. In the Properties pane, click the  Settings icon, and complete the fields as described in the following table:

    Field

    Action

    Example

    Record Definition Name

    Select the record definition that contains the attachment field in which the image is stored.

    Field Name

    Select the attachment field of the record definition in which the image is stored.

    Record ID

    Click Edit to build an expression that points to the record instance ID.

    Horizontal AlignmentSelect the appropriate alignment for the image.
    Maximum Width
    Default value—The original width of the image.
    Specify the maximum width for the image in pixels or percentage.

    Note: If these fields are blank, the image is displayed by using its original dimensions.

    HiddenSelect if you want to hide this field.
  6. Click Save
    To verify the view definition, click Preview.

Result

After configuring the Image view component, the following conditions describe how the image is rendered:

  • Attached image is valid—Image is displayed correctly.
  • Attached image is invalid—Image is not displayed. An icon indicating broken image is displayed.
  • Attachment is absent—Image is not displayed.
Was this page helpful? Yes No Submitting... Thank you

Comments