How to read ui text and use it with button?

In my game users can convert their golds to energy. 10 golds equals 100 energy. All i want that let the users decide how much energy they will buy. Want something they will type their desired energy to text or anything and click the button to buy it. New to UE5 hope you can help :slight_smile:

Add an Editable Text widget and override its onTextCommited, something like:

Use the button to buy - not sure about the rest of the logic as we don’t know what goes where. Converting is matter of taking 10x as much gold as you give them energy.