test.bat

mode con lines=2000
cscript.exe /x E:\PersonalSet\Desktop\test.vbs
pause

test.vbs

Dim fso
Set fso = CreateObject("Scripting.FileSystemObject")
StrCurPath = fso.GetFolder(".")
WScript.StdOut.WriteLine StrCurPath

-----------------------------------------------------------------------

结果是输出了test.bat所在路径

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-07-09
  • 2021-06-20
  • 2021-11-23
  • 2021-11-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-08-19
  • 2021-11-14
  • 2021-12-25
  • 2022-12-23
相关资源
相似解决方案