cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
pearldrumbum
Frequent Visitor

Create link to newly created SharePoint item

I have a powerapp form that submits all the entered fields as a new item in a sharepoint list. It also fires off a flow that sends a confirmation email. I'd like to include a link in the email to the newly created item in the SharePoint list.

 

I tried just creating a node in the email flow and entering ThisItem.'{link}' as the argument in the Email.Run() method but it says that's an invalid paramter. I then tried Text(ThisItem.'{link}') and it accepted it, but the string was blank.

 

How can I accomplish this?

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: Create link to newly created SharePoint item

Hi,

 

I would suggest to use the LastSubmit property of your EditForm. 

When you submit a new or existing form to a DataSource, you can retrieve it's properties by using the LastSubmit property of the form. 

On your flow, use a PowerApps trigger and a 'Ask in PowerApps' variable for the item URL in the mail body.

Then, you flow will expect parameters when it's called from PA :

On your submit button you can do something like :

SubmitForm(EditForm1)

 Then on the form OnSucces property : 

SendEmailFlow.Run(EditForm1.LastSubmit.{Link to Item})

(I am not sure for the {Link to Item} syntaxe, just have a look on a suggested properties availables.

 

Theo

View solution in original post

3 REPLIES 3
Brentless Kudo Kingpin
Kudo Kingpin

Re: Create link to newly created SharePoint item

From the flow that is sending the email, possibly try a "Get Items" and find the most recent item with the same title you created.  Then you can construct the link based on the returned ID, as well as any other fields in that item you want to include in the email.

TopShelf-MSFT Community Champion
Community Champion

Re: Create link to newly created SharePoint item

Thank you for the suggested solution @Brentless@pearldrumbum can you advise if this helped?

 

@TopShelf-MSFT

Super User
Super User

Re: Create link to newly created SharePoint item

Hi,

 

I would suggest to use the LastSubmit property of your EditForm. 

When you submit a new or existing form to a DataSource, you can retrieve it's properties by using the LastSubmit property of the form. 

On your flow, use a PowerApps trigger and a 'Ask in PowerApps' variable for the item URL in the mail body.

Then, you flow will expect parameters when it's called from PA :

On your submit button you can do something like :

SubmitForm(EditForm1)

 Then on the form OnSucces property : 

SendEmailFlow.Run(EditForm1.LastSubmit.{Link to Item})

(I am not sure for the {Link to Item} syntaxe, just have a look on a suggested properties availables.

 

Theo

View solution in original post

Helpful resources

Announcements
MBAS Gallery 2020

MBAS Gallery 2020

Watch Microsoft Business Applications Summit sessions on-demand.

firstImage

New Ranks and Rank Icons released on April 21!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power Apps Community!

Top Solution Authors
Top Kudoed Authors
Users online (5,877)