![Net use - 使用 c$ 而不是 c$\subfolder 时遇到错误 53](https://linux22.com/image/1554726/Net%20use%20-%20%E4%BD%BF%E7%94%A8%20c%24%20%E8%80%8C%E4%B8%8D%E6%98%AF%20c%24%5Csubfolder%20%E6%97%B6%E9%81%87%E5%88%B0%E9%94%99%E8%AF%AF%2053.png)
当我在 Powershell 中运行这段代码时:
net use \\$computerName\c$\ $adminPW /user:$adminUN /Persistent:No
我得到:
System error 53 has occurred.
The network path was not found.
但是,如果我运行:
net use \\$computerName\c$\subfolder $adminPW /user:$adminUN /Persistent:No
假设存在,它会成功执行subfolder
。为什么会发生这种情况?我正在运行此代码以便最终在其中创建一个文件夹c$
,也许还有其他方法?