If you want the windows user regardless of how the connection is made to PI, can you use
to get the username instead?
VBA.Environ("username") works perfect for me.
Hi Jun, to add on to what Daphne said, you can also try the property
and use Mappings for authentication (NO Trust!) to a different PIUser/PIIdentity for each user since the user will then have to be authenticated to be able to write a string in to the PI String Tag.