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. CALLING AN EXE FROM C# CODE

CALLING AN EXE FROM C# CODE

Scheduled Pinned Locked Moved C#
csharp
4 Posts 4 Posters 1 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.
  • V Offline
    V Offline
    vnr
    wrote on last edited by
    #1

    Hi, In my application i am using multi threading.For each thread i am calling an exe using System.Diagnostics.Process .What my doubt is if i have 100 threads then i need to call that exe for 100 times so will this degrade the performanace of application .I was not able to handle that code (which has written in exe) in my project thats why i hav written that in seperate application and calling that exe in my project.Just i wanted to know is this a correct way. Thank You

    L C K 3 Replies Last reply
    0
    • V vnr

      Hi, In my application i am using multi threading.For each thread i am calling an exe using System.Diagnostics.Process .What my doubt is if i have 100 threads then i need to call that exe for 100 times so will this degrade the performanace of application .I was not able to handle that code (which has written in exe) in my project thats why i hav written that in seperate application and calling that exe in my project.Just i wanted to know is this a correct way. Thank You

      L Offline
      L Offline
      Lev Danielyan
      wrote on last edited by
      #2

      I think it will definitely degrade the performance. You can use ThreadPool to limit/control the concurrent threads that load your external program.

      Regards, Lev

      1 Reply Last reply
      0
      • V vnr

        Hi, In my application i am using multi threading.For each thread i am calling an exe using System.Diagnostics.Process .What my doubt is if i have 100 threads then i need to call that exe for 100 times so will this degrade the performanace of application .I was not able to handle that code (which has written in exe) in my project thats why i hav written that in seperate application and calling that exe in my project.Just i wanted to know is this a correct way. Thank You

        C Offline
        C Offline
        Christian Graus
        wrote on last edited by
        #3

        100 threads are rarely if ever going to perform as well as a couple of well though out threads. Not unless you have 100 processors. I can't work out exactly what you're doing, from your description.

        Christian Graus Driven to the arms of OSX by Vista.

        1 Reply Last reply
        0
        • V vnr

          Hi, In my application i am using multi threading.For each thread i am calling an exe using System.Diagnostics.Process .What my doubt is if i have 100 threads then i need to call that exe for 100 times so will this degrade the performanace of application .I was not able to handle that code (which has written in exe) in my project thats why i hav written that in seperate application and calling that exe in my project.Just i wanted to know is this a correct way. Thank You

          K Offline
          K Offline
          KarstenK
          wrote on last edited by
          #4

          I dont know so much about C#, but cant you start a bunch of threads in one exe module. In C++ there are Threading-Functions, like AfxBeginThread which do so. You probably got to redesign than your code. :~

          Greetings from Germany

          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