Make a Text input As Hyperlink in Power Apps [Launch Outlook in a New Tab]

While developing a Power Apps application, I encountered a new issue: We needed to make a text hyperlink that should open in a new tab. Let’s discuss the requirements below intensely.

In this tutorial, I will explain the best way to make a text input as hyperlink in Power Apps using a simple scenario.

Refer to the screenshot below as well.

Make a Text input As Hyperlink in Power Apps

Make a Text input As Hyperlink in Power Apps

Let’s discuss the whole scenario.

I have a SharePoint list named Software Details with all the fields (with various data types) below:

ColumnData type
Software NameTitle – Single line of text
CostNumber
Company NameSingle line of text
ExpertsMultiline text
PlatformChoice [Windows, Mac, Linux]
powerapps add hyperlink to text

I have a Gallery in Power Apps that includes all the SharePoint list data [Software Details]. Additionally, when the user clicks a specific DETAILS button, it redirects them to an edit form that opens the particular item details.

How to Make a Text input As Hyperlink in Power Apps

In the edit form, there will be a field called Experts with multi-line text. Also, there will be a Button control that helps the user add the current user name to the experts field when the user taps on it.

Format Power Apps Text input As Hyperlink

For adding the current user name in the Expert field, I have added the code below on the Add Expert button’s OnSelect property:

Set(
    UpdatedText,
    If(
        Not(IsBlank(DataCardValue4.Text)) && !IsMatch(
            DataCardValue4.Text,
            User().FullName
        ),
        DataCardValue4.Text & ", " & User().FullName,
        If(
            IsBlank(DataCardValue4.Text),
            User().FullName,
            DataCardValue4.Text                     // If none of the condition are met, keep the existing text
        )
    )
);
// Now, patch the updated value to the SharePoint list
Patch(
    'Software Details',
    LookUp(
        'Software Details',
        ID = Gallery1.Selected.ID
    ),                                                                     // Find the item in SharePoint using the ID
    {Experts: UpdatedText                          // Patch the UpdatedText value to the Expert column
}
);
Set(
    varShowPopup,
    false
)

Where,

  • DataCardValue4 = Expert Field Data Card Value
  • User().FullName = Current User full name
  • Gallery1 = Gallery control name

Once the user clicks on the name (from the Expert field), their specific Outlook email should open. Assume that clicking on Patti Fernandez should open my email Outlook (in a new tab) if I am the current user.

However, the code and example above concatenates and displays the current user’s full name; it does not click or launch Outlook.

To achieve it, we need to follow the instructions below carefully.

  1. Select the Edit form and go to the Properties pane. Click Edit fields -> Select More actions () -> + Add a custom card.
power apps add hyperlink to text

2. Place the new data card below the form and above the Add Expert button as shown below.

Add Link to Text in Power Apps

3. insert a Gallery control (either Blank vertical or Blank horizontal gallery) inside the new Data card. Most of the time, while adding the gallery, it comes outside of the form.

If so, then cut the gallery and paste it inside the new data card.

Add Link to Text in PowerApps

4. Select the gallery control and add a Button (+ Insert -> Button). The button will now be reflected throughout the gallery, as shown in the screenshot below.

Make a Text input As Hyperlink in PowerApps

5. Next, select the gallery and set its Items property as:

Items = Split(DataCardValue4.Text,",")

Where,

DataCardValue4 = Experts field from the edit form

how to add hyperlink in powerapps form

6. Select the button from the gallery and set its Text property as:

Text = ThisItem.Value

Once you provide the code above, you can see all the user names from the Experts field at each button.

how to add hyperlink in power apps form

7. Now, apply the formula below on the button’s OnSelect property as:

OnSelect = Launch("mailto:" & ThisItem.Value)

Where,

Launch = It helps to launch a webpage or website

Add hyperlink text in power apps form

8. That’s it. Finally, save, publish, and preview the app. Select any item from the dashboard gallery and the specific detail form will open with all the information.

A new button (with the current user name) will appear in the gallery below once you hit the Add Expert button to enter the current user name into the Experts field.

When the user clicks that new button, it will launch the specific Outlook in a new tab, similar to the gif below.

Make a Text input As Hyperlink in Power Apps

Additionally, if you go to the specific SharePoint list (refresh it) and check the particular item, you can see that the new experts have updated the exact software.

Power Apps Make a Text input As Hyperlink

I hope this article will help you learn a new technique for formatting text input as a hyperlink in a Power Apps form. We also saw how to make the Power Apps text clickable and open the specific Outlook in a new tab.

Moreover, you may like some more Power Apps tutorials:

Power Apps functions free pdf

30 Power Apps Functions

This free guide walks you through the 30 most-used Power Apps functions with real business examples, exact syntax, and results you can see.

Download User registration canvas app

DOWNLOAD USER REGISTRATION POWER APPS CANVAS APP

Download a fully functional Power Apps Canvas App (with Power Automate): User Registration App