title: Running .cmd file by C#
body: <p>I am using the mentioned code to run a cmd file. It is working properly in my local machine. However when I am running in a remote machine windows security warning is coming. How can i bypass that security warning. Any help?</p>
  <pre><code>string[] newFilePath = Directory.GetFiles(workingDir, &quot;*.cmd&quot;);
  foreach (var n in newFilePath) {
      finishedOld = false;
      Process p = new Process();
      p.StartInfo.FileName = string.Format(&quot;\&quot;&quot; + n + &quot;\&quot;&quot;);
      p.Start();
      p.WaitForExit();
      p.Dispose();
      finishedOld = true;
  }
  </code></pre>
  <p><a href="https://i.stack.imgur.com/6AEMA.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/6AEMA.png" alt="image of security warning" /></a></p>