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 / copy or duplicate the ...
Power Apps
Answered

copy or duplicate the value to other text input

(0) ShareShare
ReportReport
Posted on by 418

Hi,

 

Just to get an idea and logic.. how do i copy/duplicate the invoice value to payment value using collection? So that, if user keyin the invoice value, the payment value will follow exact from invoice value. But for payment value can be change by user before save to collection.

twister_0-1613793375187.png

 

Thanks

Categories:
I have the same question (0)
  • Verified answer
    WarrenBelz Profile Picture
    153,117 Most Valuable Professional on at

    @twister ,

    I am assuming these are in cards in a form?

    On the OnChange on the Invoice Amount Text Box, put

    UpdateContext({varAmount:Value(Self.Text)});
    Reset(YourPaymentAmountTextBoxName)

    Make the Default of the Payment Amount Text Box

    If(
     varAmount>0,
     varAmount,
     Parent.Default
    )

    If these are not on a form, you can just make it varAmount and you will not need the Reset

    Lastly on the end of your Save code 

    UpdateContext({varAmount:0});

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

  • twister Profile Picture
    418 on at

    actually im using textinput in gallery with repeating table with collection.. is the formula are same?

  • WarrenBelz Profile Picture
    153,117 Most Valuable Professional on at

    @twister 

    Not quite - you can leave off the Parent.Default and would need ThisItem.FieldName if the control is bound to a field in the gallery data source.

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

  • twister Profile Picture
    418 on at

    looks like almost working.. but only 1 more issue i detect..if i keyin new record for invoice payment, the value save in will also change.. how to cater this?

    twister_2-1613898879522.png

     

    in collection already in place..

    twister_1-1613898851903.png

     

  • WarrenBelz Profile Picture
    153,117 Most Valuable Professional on at

    @twister ,

    That is why you need to reset varAmount on your save code as noted earlier.

     

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

     

  • twister Profile Picture
    418 on at

    perfectly.. now its working as expected.,.. thanks @WarrenBelz 

  • WarrenBelz Profile Picture
    153,117 Most Valuable Professional on at

    @twister 

    Please remember to click Accept as solution if my post helped you solve your issue. This will help others find it more readily and also closes the item. 

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 765 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 272

Last 30 days Overall leaderboard