cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Pitfrog1
Level: Powered On

Referencing an Attachment with UpdateIf function

Hi @ALL,

 

it is driving me crazy,I have a form with several datacards and on of them is the attachment data card of my sharepoint list. It is enabled that someone can attach a file to this field.

 

Below is my "Save" Button Code for Updating the data cards under condition. I also need to update the attachment column but it is not working, it always shows me an error that the name is invalid. But 'Attachments' is the name of data card made by PowerApps and right now I am not able to reference to it

If(Value5.Text<>"Closed",

UpdateIf(Requests,ID=EditRecord.ID,{Status:Value5.Text,
SupplierMail:_SupplierMailDropdown.SelectedText.SupplierMail,
SupplierContactPerson:_CCMailDropdown.SelectedText.CCMail,
AssignedTo:assign,
DateClosed:"--",
BusinessServiceTypes:_DataCardValue1.Text,
Priority:Value8.Text,
Comment:Value3.Text}),

    UpdateIf(Requests,ID=EditRecord.ID,{Status:Value5.Text,
'Attachments':_DataCardValue2.Attachments,
SupplierMail:_SupplierMailDropdown.SelectedText.SupplierMail,
SupplierContactPerson:_CCMailDropdown.SelectedText.CCMail,
AssignedTo:assign,
DateClosed:_DatumHeute.Text,
BusinessServiceTypes:_DataCardValue1.Text,
Priority:Value8.Text,
Comment:Value3.Text}));

Navigate(DashboardPage,ScreenTransition.Fade)

 I would appreciate it if you could help me. This step is really crucial for the employees to save other attachments.

 

BR

Pitfrog

2 REPLIES 2
Super User
Super User

Re: Referencing an Attachment with UpdateIf function

There is a limitation with the Attachment control where changes can only be saved using the SubmitForm() function. 



--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.
Pitfrog1
Level: Powered On

Re: Referencing an Attachment with UpdateIf function

@Jeff_Thorpe 

 

So, as far as I understand you, I need to split my Form into two forms, one with my conditions and one solely for the attachment control? 

 

Is there any proposal here or this function? 

 

BR
Pitfrog

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors (Last 30 Days)
Users online (4,612)