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

Attachments aren't saved

I have a form with 4 screens, at the last screen I set attachments via a form connected with an item and the attachments control on this.

 

 

I have a save button, which should save the attachments to the form. Now this one works only part of the times... So my attachments are stored DataCardValue, so what I did I tried to save my count to a SharePoint list via counting the attachments: CountRows(DataCardValue.Atachments). This functionality also only works when the attachments save button does it's work... The other times it just saves a 0 (when I show this value on the screen, it does show the correct number)...

 

Not everytime, I'm pulling my hear to solve this one... 

1 ACCEPTED SOLUTION

Accepted Solutions
DriesVerdonckt
Level: Powered On

Re: Attachments aren't saved

I've restructured my code and made sure the attachments are saved and let the user from then on navigate to the next screen (using the error functionality). This seems to work!

 

Thanks though for the elaborate answer!

View solution in original post

3 REPLIES 3
Community Support Team
Community Support Team

Re: Attachments aren't saved

Hi @DriesVerdonckt,

 

Do you want to save the Count Ataachments’ files number to your SP list?

Is CountRows one column in your SP list?

What the formula expression of your save button?

You can use submit form or save button to save attachments and the count number.

 

I test as next, I think you can try following workaround:

DataSource:

20190206dropdownformmode (My SP list name)

CountAttachments (number type)

20190206saveattachmentsp1.png

App Test:

 You can use Submit or one button to save your form.

DataCardValue8.Default= CountA(DataCardValue7.Attachments.Value)

20190206saveattachmentapptest1.jpg

Method 1:

Use Submit Form.

Result Test:

20190206saveattachmentresulttest1.gif

20190206saveattachmentsp2.png

Method2:Use Button.

Add one Button, and Buttton1.OnSelect: Patch('20190206dropdownformmode',Defaults('20190206dropdownformmode'),{CountAttachments:Value(DataCardValue8.Text),Title:DataCardValue5.Text},Form2.Updates)

Result Test:

20190206saveattachmentresulttest2.gif

20190206saveattachmentsp3.png

 

 

Hope this can be helpful.

Best Regards.

Yumia

DriesVerdonckt
Level: Powered On

Re: Attachments aren't saved

Hi, 

 

Thanks for the answer, what you describes is exactly how I submit my form, the thing is... it only works 50% of the time, the other times it just doesn't do anything... 

 

Counting rows was my idea to check the number of attachment (when the submit wouldn't save my attachments, at least I knew if a user had uploaded attachments and how may). BUT... for the moment I save the number of rows or submit the form with attachments, it seems like the attachmentscontrol (datacardvalueX) is reset and looses its value...

 

 

DriesVerdonckt
Level: Powered On

Re: Attachments aren't saved

I've restructured my code and made sure the attachments are saved and let the user from then on navigate to the next screen (using the error functionality). This seems to work!

 

Thanks though for the elaborate answer!

View solution in original post

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 (5,210)