2
I am making a simple program with Visual Studio to run some commands on CMD that I want, currently the program has only a simple screen and a button to open cmd, but I would like to specify the command that the prompt should run.
Ex: Ipconfig, flushdns, etc.
Currently my code is like this, using the System.Diagnostics
namespace Comands
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void button_Click(object sender, EventArgs e)
{
System.Diagnostics.Process.Start("CMD.exe");
}
}
}