Skip to main content

Notifications

Community site session details

Community site session details

Session Id : Rz5JSpz+Tutpjp2V2BNRH1
Power Automate - Building Flows
Answered

Creating A Link to a specific form response

Like (0) ShareShare
ReportReport
Posted on 24 May 2019 15:58:13 by 109

I'm trying to figure out if there is a way to format a linke to a reponse in MS Forms.  I would like to add a 'click here' type of link to an e-mail flow each time a response is submitted.  I don't really need to emebed the detail variables into the message since the users who need the data will all have access to the form responses.

  • David_MA Profile Picture
    10,790 Super User 2025 Season 1 on 07 Nov 2024 at 19:19:46
    Creating A Link to a specific form response
    queenc23 this is a great solution. Have you figured out how to generate the URL to the editable form when you allow users to edit their response? It seems most of what you already provided would work, you just need the response token and the URL I think would be:
     
     
    I looked through some runs of a flow in the Get response details, and I don't see anything that matches the Token ID when I submit a form and open it to edit.
  • queenc23 Profile Picture
    4 on 15 Jul 2024 at 19:21:32
    Re: Creating A Link to a specific form response

    I was able to figure this one out.  Here's what I did for the variables:

     

    1. Initialize Variable
    2. Initialize Variable 2
      • Name: ResponseID
      • Type: Integer
      • Value: 0
    3. Set Variable
      • Name: ResponseID
      • Value: sub(int(triggerOutputs()?['body/resourceData/responseId']), 1)
    4. Set Variable 2

     

    Hope this helps.

     

     

  • imangaliman Profile Picture
    2 on 08 Jul 2024 at 08:10:10
    Re: Creating A Link to a specific form response

    Hi Marc, any chance you found a solution to get the ResponseToken? I'm trying to save the link of each fulfilled forms in a SharePoint List. I'm the only one who answers the form, but getting the saved responses in "fulfilled forms" tab is somehow tricky.

  • anonymous2024 Profile Picture
    2 on 30 Apr 2024 at 17:09:00
    Re: Creating A Link to a specific form response

    this is fantastic! I'm very close but would it be possible to show the expanded view of each of those steps? So that I can see 'Name' , 'Type' , and 'Value' for each of the variable steps? would be greatly appreciated

  • Clifferton Profile Picture
    94 on 15 Mar 2024 at 23:40:23
    Re: Creating A Link to a specific form response

    @kinnett You can do the whole thing with the compose action too, rather than using variables. I used variables because they were easier to use in my multi-level flow. Using compose simplifies the whole thing quite a bit. You could even do it in one compose action, but I think it's easier to break up math actions from string actions.
    Here's a simple example.

    Clifferton_0-1710545255882.png

     

    Inside the subtraction compose action, have the following expression which adds negative 1 to the response ID. @Amira703 If you just grab the response ID from the dynamic content you get from the Get Response Details action, it will be the one that was most recently submitted.

     

    add(-1,triggerOutputs()?['body/resourceData/responseId'])

     

     

    Inside the Compose URL action, I have this input. This prevents you from having to muck around with concatenate expressions. The dynamic content here is just the output from the subtraction compose action.

    Clifferton_1-1710545447645.png

     

    Then in the email, I find it easier to create the link within the HTML code instead of trying to get dynamic content into the WYSIWYG editor. The dynamic content here is the output from the URL compose action.

    Clifferton_2-1710545616765.png

     

    Then the URL is actually a link in the email so folks can just click it instead of having to copy and paste.

    Screenshot 2024-03-15 173545.png

  • kinnett Profile Picture
    2 on 14 Mar 2024 at 17:50:39
    Re: Creating A Link to a specific form response

    I have tried this multiple times and keep getting the error- "enter a valid integer".  Can you clarify for me what goes in each of these boxes?   I assumed this went into "initializing variable 2", but I keep receiving the "enter a valid integer" error

    3. Initialize variable: responseURL (String)
    4. Initialize variable 2: responseID (Integer)
    5. Set variable
    6. Set variable 2

      

  • Amira703 Profile Picture
    9 on 01 Dec 2023 at 17:51:42
    Re: Creating A Link to a specific form response

    I'm not very experienced with initializing and setting variables. Are you able to open those steps to show the code inside?

     

    The way I'm doing it must be wrong since the URL that results defaults to the first response vs. most recent. The ridx number increases by one each time, but how to do I code it to go to the most recent ridx?

  • Clifferton Profile Picture
    94 on 13 Sep 2023 at 20:57:02
    Re: Creating A Link to a specific form response

    Angelwing,

    Your images don't show where or how you modified the URL to create the link to the form responses. If you include more detail there, we might be able to help.

  • Clifferton Profile Picture
    94 on 13 Sep 2023 at 20:51:40
    Re: Creating A Link to a specific form response

    KES2,

    Sorry for the late reply. Here is a page on using variables in Power Automate. You need to "initialize a variable" first. In that step, you'll name the variable and choose the type of variable (string).

    The compose step is a bit more difficult to explain, but if you look at @goncaloperes's post right above yours, you'll see a clearer explanation.

     

    In the future, if you have a question that does not fit the topic of a discussion, such as how to use variables, you should probably start a new thread.

     

    ~C

  • angelwing350 Profile Picture
    2 on 31 Aug 2023 at 17:22:02
    Re: Creating A Link to a specific form response

    Hi goncaloperes,

     

    I tried your method and everything worked except when the email is received, the link gets an error that the form doesn't exist. I have attached a view of the process as it is now. Can you help?

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Congratulations to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,776 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 66,093 Most Valuable Professional

Leaderboard