Run batch file in vb.net?

You can use the Process class to run a batch file

Dim psi As New ProcessStartInfo("Path TO Batch File")
psi.RedirectStandardError = True
psi.RedirectStandardOutput = True
psi.CreateNoWindow = False
psi.WindowStyle = ProcessWindowStyle.Hidden
psi.UseShellExecute = False

Dim process As Process = Process.Start(psi)

Leave a Comment