I need execute a command line in a Visual Basic Script

后端 未结 3 634
小蘑菇
小蘑菇 2020-12-16 01:43

I need to execute the command \"ver\" in my vbs to see the version of my Operating System, and i don\'t know how make it.

I tried this, but dont work:



        
3条回答
  •  情深已故
    2020-12-16 01:44

    Dim shell
    Set shell= WScript.CreateObject ("WScript.shell")
    shell.Exec"cmd /c ver"
    Set shell= Nothing
    

提交回复
热议问题