Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C#
  4. process

process

Scheduled Pinned Locked Moved C#
csharptutorial
4 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Offline
    L Offline
    lankaudaranga
    wrote on last edited by
    #1

    how to stop computer running process and start process using c#.

    R J S 3 Replies Last reply
    0
    • L lankaudaranga

      how to stop computer running process and start process using c#.

      R Offline
      R Offline
      rah_sin
      wrote on last edited by
      #2

      try System.Diagnostics.Start to strat external process.

      rahul

      1 Reply Last reply
      0
      • L lankaudaranga

        how to stop computer running process and start process using c#.

        J Offline
        J Offline
        Judah Gabriel Himango
        wrote on last edited by
        #3

        Start and stop processes? Is that what you're asking? If so, look at System.Diagnostics.Process class.

        1 Reply Last reply
        0
        • L lankaudaranga

          how to stop computer running process and start process using c#.

          S Offline
          S Offline
          smilethat
          wrote on last edited by
          #4

          you can start process using c# by this way: using System.Diagnostics ....... Process.Start("notepad.exe"); ....... Process.Start("cmd",@"/c mysqldump --user=root --password=123 mysql > c:\db.sql -t");//useful ....... Process.Start("notepad.exe","c:\\record.txt"); ....... Process.Start("IEXPLORE.EXE","http://jnjx.126.com"); ....... Process.Start(@"C:\myFiles\MyApp.exe"); ..... and you can stop the process usingC# by this way: //you can use the function using System.Diagnostics; .......... private void KillProcess(string processName) { Process myproc= new Process(); // try { foreach(Process thisproc in Process.GetProcessesByName(processName)) { thisproc.Kill(); } } catch(Exception Exc) { MessageBox.Show(Exc.Message); } } //you can call this function like :KillProcess("iexplore.exe");

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups