You probably have Setoption("Explicit", "On") at the top of your script. If you do then you need to use DIM to declare all variables.

The $sNul is used to catch the return code of the writevalue function. You can leave it out but then you will see the return code on the screen.
_________________________
Mart

- Chuck Norris once sold ebay to ebay on ebay.