cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
pNabin
Advocate V
Advocate V

Copy and save attachment from Collection into Sharepoint

Hi,

I need to copy some of the fields of existing sharepoint items and make some modifications into it ans save it as a new item.

In First screen (Form in View mode), I saved the selected item into the Collection.

In Second Screen (Form in New mode), I set up a default values of the fields i need to copy from collection I created in First screen including attachment field. All fields and attachments is defaulted into the new form and I can add new attachments which also shows all previous attachments. While saving by SubmitForm(NewFormCopy), everything is saved including newly added attachments but the attachments which is copied is not saved.


Any ideas, what could be the the problem?

 

Formulas I used:

To copy gallery item into collection: 

ClearCollect(CopyOfRequest,{Title: MyGallery.Selected.Title,Documents:MyGallery.Selected.'{Attachments}'});

Navigate(NewCopyScreen,ScreenTransition.None)

 

To add attachment into Default value of Attachment in new form: First(CopyOfRequest).Documents

 

To save the new item: SubmitForm(NewFormCopy)

3 REPLIES 3
v-xida-msft
Community Support
Community Support

Hi @pNabin,

 

Do you want to modify an existing item or create a new item within your app?

 

I suppose that you want to create a new item within your app with copied Attachments from a collection, is it true? I have made a test and the issue is confirmed on my side. 

 

The Attachments control lets users open files stored on a data source as well as add and delete files from a SharePoint list. Currently, we could only upload new attachments into a new SP list item via clicking Attach file button within the Attachments control.

 

If you want to create a new item within your app with copied Attachments from a collection, I afraid that there is no way to achieve your needs in PowerApps currently.

 

If you would like this feature to be added in PowerApps, please submit an idea to PowerApps Ideas Forum:

https://powerusers.microsoft.com/t5/PowerApps-Ideas/idb-p/PowerAppsIdeas

 

 

Best regards,

Kris

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

@v-xida-msft,

You are right, I need is Create a new item by copying existing item including attachments.

Is there any workaround for this scenario you are aware of?  

 

Thanks,

Nabin

victore
Advocate I
Advocate I

Has anyone contacted you about this issue? Did you resolve the issue?

Helpful resources

Announcements
Ignite 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Power Apps Africa Challenge 2022

Power Apps Africa Challenge

Your chance to join an engaging competition of Power Platform enthusiasts.

Users online (1,751)