Run batch file in vb.net?

前端 未结 4 435
臣服心动
臣服心动 2020-11-27 06:58

How can I run a batch from from within vb.net?

4条回答
  •  独厮守ぢ
    2020-11-27 07:36

    'The easiest way if you know the exact location of the file is

    System.Diagnostics.Process.Start("c:\test\file.bat")

    'In Visual Studio the file must exist in the /bin/debug or /bin/release depending on your current build configuration

    System.Diagnostics.Process.Start("test.bat")

提交回复
热议问题