Hello all.
I'm trying to use a button to update a DataCardValue in a "New" form inside my PowerApp but the UpdateContext function doesn't seem to be working for me like I've seen other people using it. I'm wanting to take whatever value exists currently in a given DataCardValue, and increase it by a count of 1 when the button is pressed.
I've tried several variations on this:
UpdateContext({DataCardValue41: DataCardValue41.Text + 1})
I've tried leaving off the .Text with no success. Also, I've tried using the Sum function with another label titled PlusOne, so I'd end up with something like this:
UpdateContext({DataCardValue41: Sum(DataCardValue41.Text, PlusOne.Text)})
I'm dealing with DataCardValues that are either empty or will have a 0 in them. I can do either, if I need to put 0's in as a default value then that's fine.
Thanks in advance!