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 / Calculations with Text...
Power Apps
Unanswered

Calculations with Text Input and Patch to Data Source

(0) ShareShare
ReportReport
Posted on by 240

Hello Everyone,

 

Hope you are all well,

 

I am a bit stuck, I have a Text Input within a gallery that i need to be 2 other text inputs added together. I also need it to patch back to my data source and update the cells within that. The problem is that isn't currently happening.

 

I am using this as the default property of that text input:
Round(TextInput1 + TextInput1_1,2)

 

The OnChange property is:

Patch(Calcs2,ThisItem,{'Payroll £ value ':TextInput1_2.Text})

 

Any help as always is very much appreciated!

 

Many Thanks

Chris

Categories:
I have the same question (0)
  • SebS Profile Picture
    4,686 Moderator on at

    @Appy1 

     

    Change Round(TextInput1 + TextInput1_1,2) to :

     

    Round(TextInput1.Text + TextInput1_1.Text,2)

     

    Than Patch if Your column is type Number

     

    Patch(Calcs2,ThisItem,'Payroll £ value ': Value(TextInput1_2.Text))

     

  • CC-19121430-0 Profile Picture
    240 on at

    Hello @SebS 

     

    Thanks for your suggestion, i have given it a go and seem to be getting an error on the Patch - OnChange.

    Appy1_0-1679680816623.png

    Are you able to advise?

     

    Thanks very much

    Chris

  • SebS Profile Picture
    4,686 Moderator on at

    @Appy1 

     

    My bad forgot about {} 🙂

     

    Patch(Calcs2,ThisItem,{'Payroll £ value ': Value(TextInput1_2.Text}))

     try again 

  • CC-19121430-0 Profile Picture
    240 on at

    Hi @SebS ,

     

    Thanks, still not quite working unfortunately.

     

    This is now the error received:

    Appy1_0-1679689471196.png

    Many thanks

    Chris

  • SebS Profile Picture
    4,686 Moderator on at

    @Appy1 

     

    Sorry, that must be me today 🙂 all that typos today not good 🙂

     

    Patch(Calcs2, ThisItem, { 'Payroll £ value': Value(TextInput1_2.Text)})

     

  • CC-19121430-0 Profile Picture
    240 on at

    Thanks! @SebS 

    Haha no worries, one of those days 😄 The formula now works and no error there.

     

    Unfortunately it doesn't seem to be patching it to my data source though the cells happen to still be blank there.

     

    Many thanks

    Chris 

  • SebS Profile Picture
    4,686 Moderator on at

    @Appy1 

     

    The problem is not in Patch but in how you want to patch it.

     

    You are using OnChange if the expectation is that when TextInput1 and TextInput2 will be input, that will trigger TextInput1_2.Text OnChange will never happen without physically pressing something that controls, so question is, in what control property are you using on change ?

  • CC-19121430-0 Profile Picture
    240 on at

    Hi @SebS 

     

    Sorry i seem to have accidentally accepted the solution rather than click reply, i hope you can still help me please.

     

    I think i understand what you are saying, is it that i would need a save button? Is that would your recommendation would be?

     

    Thanks

    Chris

     

  • SebS Profile Picture
    4,686 Moderator on at

    @Appy1 

     

    if you input data to text inputs in a sequence like  TextInpu1 than TextInput2 and after TextInput2 is submitted You want result of TextInput to be Patch to DataSource one of the options for You will be place code in OnChange of TextInput2 property other than that Save button will do the job 

  • CC-19121430-0 Profile Picture
    240 on at

    Thanks @SebS 

     

    What formula would I need to use within my ONSelect property of my save button?

     

    Kind Regards

    Chris

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

#2
Kalathiya Profile Picture

Kalathiya 361

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 339 Super User 2025 Season 2

Last 30 days Overall leaderboard