The advice by others is absolutely correct.
You need to use the .read and .write properties as follows...
Set Dummy = HMIRuntime.Tags(“Dummy”)
Set Test = HMIRuntime.Tags(“Test”)
If Dummy.read = 1 Then Test.write = (“Pers3”)
Else
If Dummy.read = 2 Then Test.write = (“Pers4”)...