Payment from variable amount

I’m afraid I’ve had no joy with this. It’s coming up with an error on a bracket. Also replace the myButton with an actual button number… Can I pass the total amount to a dataset, then call upon this value to use in wixpay?