That looks like a very useful script. Do you have a script to set user properties as well? If not, maybe you could extend the script to set properties, too? Good stuff!