cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ATCancom
New Member

How can we reset the attachment field?

 

We are trying to implement a new form that emulates a wizard (3 screens). If we use the Submit function, only the fields on the last screen will be saved into SharePoint. That is why we used the Patch function.

 

Now, we have the problem that the content of the "previously entered value of attachment field" is still shown in every new form.

 

Can someone help us?

 

Thanks a lot.

1 ACCEPTED SOLUTION

Accepted Solutions
v-micsh-msft
Community Support
Community Support

Hi @ATCancom,

 

Are you working with the SharePoint list custom form, or the Apps built from SharePoint list?

 

Please first review the limits for the current attachment control:

Attachment control in PowerApps

Quoted:

"

  1. Attachment upload only works with SharePoint list data sources. Support for other data sources will be introduced incrementally, starting with CDS.

  2. Upload and delete functionality only work inside a form. Attachment control will look disabled when in Edit mode and not inside a form. Note that in order to save the file additions and deletions to the back end, the end user must save the form.

"

Would you please explain a bit for "Now, we have the problem that the content of the 'previously entered value of attachment field' is still shown in every new form."?

 

If here you would like to submit new record, then please take use of NewForm() function, and if you have added multiple forms, then all the forms should be reset by the NewForm() function. As there is no Reset property available for this control, we need to Reset the form with NewForm(), in order to Reset the controls added within the form.

 

For SharePoint list custom form, under the OnNew property of the SharePoint integration.

NewForm(Form1);NewForm(Form2);...

For the Apps generated with SharePoint list data source, with the Create "+ " button, 

NewForm(Form1);NewForm(Form2);...;navigate(EditScreen, ScreenTransition.Fade )

For how to work with forms, see:

EditForm, NewForm, SubmitForm, ResetForm, and ViewForm functions in PowerApps

EditForm and Display form controls in PowerApps

 

Regards,

Michael

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-micsh-msft
Community Support
Community Support

Hi @ATCancom,

 

Are you working with the SharePoint list custom form, or the Apps built from SharePoint list?

 

Please first review the limits for the current attachment control:

Attachment control in PowerApps

Quoted:

"

  1. Attachment upload only works with SharePoint list data sources. Support for other data sources will be introduced incrementally, starting with CDS.

  2. Upload and delete functionality only work inside a form. Attachment control will look disabled when in Edit mode and not inside a form. Note that in order to save the file additions and deletions to the back end, the end user must save the form.

"

Would you please explain a bit for "Now, we have the problem that the content of the 'previously entered value of attachment field' is still shown in every new form."?

 

If here you would like to submit new record, then please take use of NewForm() function, and if you have added multiple forms, then all the forms should be reset by the NewForm() function. As there is no Reset property available for this control, we need to Reset the form with NewForm(), in order to Reset the controls added within the form.

 

For SharePoint list custom form, under the OnNew property of the SharePoint integration.

NewForm(Form1);NewForm(Form2);...

For the Apps generated with SharePoint list data source, with the Create "+ " button, 

NewForm(Form1);NewForm(Form2);...;navigate(EditScreen, ScreenTransition.Fade )

For how to work with forms, see:

EditForm, NewForm, SubmitForm, ResetForm, and ViewForm functions in PowerApps

EditForm and Display form controls in PowerApps

 

Regards,

Michael

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

I am also facing same issue with SharePoint List form. After submiting form using powerapp couple of times, it come with previous attached file by default. 

 

Any help would be appreciated.

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

May UG Leader Call Carousel 768x460.png

June User Group Leader Call

Join us on June 28 for our monthly User Group leader call!

PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

PA.JPG

New Release Planning Portal (Preview)

Check out our new release planning portal, an interactive way to plan and prepare for upcoming features in Power Platform.

Top Solution Authors
Users online (1,030)