关于利用BAT拷贝文件到系统System32下的问题。
像下面这样拷贝肯定是可以的
copy a.txt c:\windows\system32\b.txt
但为了兼容Win2000和Win9X(因为Win2000的安装目录是WINNT,Win9X的是Windows),所以想用%windir%来代替系统安装目录。
我改成如下
copy a.txt c:\%windir%\system32\b.txt
可系统不认 %windir% ,请问正确的应该怎样写?
如果可能,最好将安装盘盘符(如C:)也用系统变量代替。谢谢!