Dataset Not Submitting

Hello everyone,
there is a problem with submitting the dataset, here is what I have in my page.

  1. One user input that is connecting to AllStudents dataset to points value
  2. One button with a label ADD 50 POINTS
  3. Submit button.

When pressing the button ADD 50 POINTS the code runs and it adds 50 to the value of the input, but it is not saving when pressing the submit button. After, when changing the value by hand, it saves normally.

I have checked, the database permission is set to anyone can submit, edit, update. And the dataset on the page is set to read and write.

The problem is, when the input value is changed with the ADD 50 POINTS button, in can not recognize that the value is changed, and when pressing submit, it is not submitting, but when changing it by hand, it works perfectly. You can see it in the video attached, what is the problem?
Please help me, it is very important,
Thanks in advance.
Arman,

Video:

Probably because the submit button you are using that allows you to add pass or fail messages without using code and submits your user input is only adding it to the dataset when the value of that element is changed by manual type.

It simply doesn’t register that the value in the element has changed whenever you use the button to change the value on the element by adding fifty to the running total.

You will probably need to not use that submit to dataset button and make up your own button using code to submit the element value to the dataset.

Read the Note in the Value section in the Wix Code API link for ValueMixin below and it will explain why your page is not working perfectly.

https://www.wix.com/code/reference/$w.TextInput.html#onChange
https://www.wix.com/code/reference/$w.ValueMixin.html
https://www.wix.com/code/reference/wix-dataset.Dataset.html#setFieldValue

Thank You Dear @givemeawhisky ,
Works fantastic!!!