web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Duplicate line from Sh...
Power Apps
Answered

Duplicate line from SharePoint List when button is pressed

(0) ShareShare
ReportReport
Posted on by 83

Hi, 

 

Can you please provide some guidelines on how to copy the selected line from a Sharepoint list to a new line ?

So, I'm in a Form, edit form in Power app, of a line from a Sharepoint list. If a button is pressed in this form, I need this line to be copied as a new line ( with all the info from it) in the list.

 

Is there an easy way or simple way ?

 

Big thanks in advance.

 

Categories:
I have the same question (0)
  • Verified answer
    StalinPonnusamy Profile Picture
    Super User 2024 Season 1 on at

    Hi @SergiuTPLS 

     

    This option works best on your scenario since you already in Edit Form

    1. Create a new button on the edit form called "Save as New" or "Duplicate"

    Patch('SPList', Defaults('List'), {Columns in the form});

     

    Other Options also possible based on fields

    2. Get specific item from SP to Collection

    ClearCollect(ColSPItem, Lookup(SPList, ID= 10)); 

    Update the collection ID = blank()

    Patch(SPList, ColSPItem);

     

    3. Call the Power Automate from powerapps to create duplicate

     

    4. Have Power automate to create duplicate when some condition is met

  • SergiuTPLS Profile Picture
    83 on at

    Incredible, that is so simple and so effective! i was planning to make a Flow !🤐

    Thanks Stalin !

  • RandyHayes Profile Picture
    76,297 Super User 2024 Season 1 on at

    @SergiuTPLS 

    If you are planning to provide a separate button to be the "duplicate button", then you will need to make sure your Form is using a variable on the Item property.

    So, assuming you have a variable on the Item property of, let's say, glbCurrentRecord, then in the Duplicate button OnSelect, set the Formula to: Set(glbCurrentRecord, Patch(glbCurrentRecord, {ID: Blank()}))

    Then when you submit the form, it will duplicate the record.

     

    I hope this is helpful for you.

  • RandyHayes Profile Picture
    76,297 Super User 2024 Season 1 on at

    @SergiuTPLS 

    Sorry, I thought you were working with a record in a form.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 721 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 320 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard