Invalid when the field or state input values have been tampered with

Hi, Is it possible to use JavaScript to change the value of a field without getting the error: Invalid when the field or state input values have been tampered with.
Thanks
Luc