Hi,
do you use persistence? Then you have to use command based approach to alter process variables. See data section of engine basics chpater of documentation for code snippet.
Also make sure that you have declared your process variable in your process definition.