SetReadOnly.vbs

This script sets the readonly attribute of a file. It requires exactly three parameters:
the first parameter is the full path to the file, the second is the required Read Only state:
y or Y will make the file read only, all other characters will allow users to edit the file.
The third parameter is the full path to a log file, which will be created by the script if and only if an error occurs, in which case an error message will be written to the file (if possible).
If the special value *DEBUG is provided as the third parameter, error messages will be shown interactively.