Under which account does a start-up script run? Does a start-up script have the right to access network resources? Does the start-up script have the rights to access the hidden share? Why are you using the double '$'? If you would use SETOPTION('NoVarsInStrings','ON'), as is recomended, then the double '$' would not be necessary.

Oh, and this being the scripts forum we normally ask for script snippets, and not one-liner code fragments.
_________________________
There are two types of vessels, submarines and targets.