web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / QR Code Deep Link Issue
Power Automate
Answered

QR Code Deep Link Issue

(0) ShareShare
ReportReport
Posted on by

@v-xiaochen-msft 

 

Hello,

 

I figured out how to embed a QR code into a Word doc, but unfortunately the deep link portion of it isn't working. When I scan the QR code it opens to the Home Screen of the app versus the record screen I wish to show.

 

The QR code is created when a new record is added to the SharePoint list. The deep links I embed in the email notification sent at the end (steps now shown here) work just fine to open up the app directly to the record screen so I don't think there is an issue with my deep link formulas, just the QR code url specifically.

 

Here is the formula used in the Initialize variable step below minus some characters and the ID dynamic content block.

 

https://quickchart.io/qr?text=https://apps.powerapps.com/play/e/default-xxxx-xxx-xxxx-xxxx-xxxxx/a/xxxx-xxxx-xxxx-xxxx-xxxxxx?tenantId=xxxxx-xxx-xxxx-xxxx-xxxx&hidenavbar=true&DeepLink=DetailsScreen&RefID=

 

 

About a year ago Wearsky (tagged here) suggested that I wrap the url in an EncodeUrl function. That approach worked when I was just embedding a QR code into an email, but unfortunately it doesn't work when I embed the QR code into a Word doc.

 

EncodeURLSS.png

 

Here are the flow steps:

FirstSteps.png

SecondSteps.png

 

Here are some screenshots from the flow run:

URL returned:

 

https://quickchart.io/qr?text=https://apps.powerapps.com/play/e/default-xxxx-xxxx?tenantId=xxxx&hidenavbar=true&DeepLink=DetailsScreen&RefID=131

 

The URL is the same in the Upload file step.

UploadFile.png

 

A separate flow gets the .png file and inserts it into the Word doc. I blurred out the center of the QR code for security, but it looks like a normal QR Code. As previously mentioned, it does work to open the app, just doesn't go to the specific record like I want it to.

BoxLabel.png

I've been playing with this flow on and off for over a year now so if someone could help me figure this out, I would be very grateful!

 

Thank you,

Teresa

Categories:
  • Verified answer
    tagustin2020 Profile Picture
    on at

    @v-xiaochen-msft 

     

    Hello,

     

    I figured out what I was doing wrong. I was trying to use the EncodeURL function inside of Power Automate instead of in Power Apps.

     

    Here is the OnSelect formula for my "Create Box Label" button. The 'QR Encoded URL' is a multiline of text (plain text) SharePoint column. The 'QR Code Version' and 'PDF Version' are Number type columns with the default number set to 0. The 'Generate PDF' is a Yes/No column that is set to 'No' by default. 

    Patch(
     'CSO Archive Requests',
     {
     ID: varRecord.ID,
     'Generate PDF': true,
     'PDF Version': Value(valPDFVersion.Text) + 1,
     'QR Code Version': Value(valQRCodeVersion.Text) +1,
     'PDF Email': varUser.Email,
     'QR Encoded URL': "https://quickchart.io/qr?text=" & EncodeUrl("https://apps.powerapps.com/play/e/default-xxxx?tenantId=xxxxx&hidenavbar=true&DeepLink=DetailsScreen&RefID=") & varRecord.ID,
     'Archive Status': {Value: "Archived"}
     }
    );
    Notify(
     "A box label will be sent to your email shortly.",
     NotificationType.Success
    )

     

    Power Automate Steps:

    I used the 'When an item or a file is modified' trigger and added a condition to see whether or not 'Generate PDF' is equal to true or false.

    Condition.png

    I inserted a OneDrive Upload file step and inserted the 'QR Encoded URL' dynamic content from the 'Get item' step. I then added a OneDrive 'Get file content' step and inserted the Id that came from the 'Upload file' step. I have a SharePoint doc library called 'QRCodes'. I added a SharePoint 'Create file' step. Because my people can click the 'Create Box Label' button more than once I used not only the SharePoint ID for the name, but also the 'QR Code Version' in parenthesis after the ID. I inserted the Body from the OneDrive 'Get file content' step. 

    OneDriveSteps.png

    I added a 'Compose' step, then a 'Get file content' step. I then inserted the Body of the SharePoint 'Get file content' step into the Word doc. Note that I wrapped the outputs of the 'Compose QR Code png' step in the encodeUriComponent function (that one does work in Power Automate). I'll stop here since this post is already getting long, but if anyone wants to see the remaining steps that convert the Word doc to a PDF, attach it to the SharePoint list and email the attachment to the user that clicked the button, let me know and I'll be happy to share.

     

    WordSteps.png

     

    You will need a 2D scanner to scan QR codes. This method was successful in opening deep links to a specific record within the Power App (versus opening to the home screen of the app). Have a good day and have fun "Power Apping"!

    Teresa

     

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Automate

#1
11manish Profile Picture

11manish 317 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 247

#3
Henil Profile Picture

Henil 117

Last 30 days Overall leaderboard