To diagnose, display the value of %TEMP% - is it rooted?

If you're using the user's temp folder, it has spaces in the path - are you properly quoting the path to TEMP? I avoid using the user's temp at all costs for this reason. Also - is the TEMP relative to all scripts the same? Same user? You mention using runnas, so there might be different paths for different processes.

Since it works for a network path, I'm guessing that the TEMP environment values are not the same between all script parts. See if the @SCRIPTDIR value is the same - you might use that instead. Would be faster than using a network share.

Glenn
_________________________
Actually I am a Rocket Scientist! \:D