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
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Communication between processes

Communication between processes

Scheduled Pinned Locked Moved C / C++ / MFC
questiontutorial
5 Posts 3 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.
  • 0 Offline
    0 Offline
    0v3rloader
    wrote on last edited by
    #1

    Hello, What is the best way to make different processes send messages to one another? I mean, I know how to make different threads within the same process (app) communicate with one another, but I really don't know what is the correct way of making different threads in different processes communicate with each other... David

    W B 2 Replies Last reply
    0
    • 0 0v3rloader

      Hello, What is the best way to make different processes send messages to one another? I mean, I know how to make different threads within the same process (app) communicate with one another, but I really don't know what is the correct way of making different threads in different processes communicate with each other... David

      W Offline
      W Offline
      W00dSt0ck
      wrote on last edited by
      #2

      COM - Component Object Model for more Info, check the articles on this page regards WoodStock

      1 Reply Last reply
      0
      • 0 0v3rloader

        Hello, What is the best way to make different processes send messages to one another? I mean, I know how to make different threads within the same process (app) communicate with one another, but I really don't know what is the correct way of making different threads in different processes communicate with each other... David

        B Offline
        B Offline
        Blake Miller
        wrote on last edited by
        #3

        Depends on what you are trying to do. 1. If all your processes are on the same machine, and you don't need a lot of data, or the data is of the same format every time, you can use memory mapped files. 2. You can use TCP/IP and sockets to send data back and forth, also works over the network. 3. If it is a TINY amount of infrequent data, with no return recipt required, you could look into MailSlots. 4. Hey, you can even use COM, but what a pain in the backside! (Marshaling data, getting hrreading mdoels and initialization to work right, DCOM settings, etc.) 5. You can use Local RPC (everything running on same computer) or Remote RPC (not necessarily on same computer). 6. WM_COPYDATA - sending data between windows of different processes. Your question is impossible to answer appropriately without more details. But you might want to read a little bit about each of the technologies mentioned here, and then you can make your own decision.

        0 1 Reply Last reply
        0
        • B Blake Miller

          Depends on what you are trying to do. 1. If all your processes are on the same machine, and you don't need a lot of data, or the data is of the same format every time, you can use memory mapped files. 2. You can use TCP/IP and sockets to send data back and forth, also works over the network. 3. If it is a TINY amount of infrequent data, with no return recipt required, you could look into MailSlots. 4. Hey, you can even use COM, but what a pain in the backside! (Marshaling data, getting hrreading mdoels and initialization to work right, DCOM settings, etc.) 5. You can use Local RPC (everything running on same computer) or Remote RPC (not necessarily on same computer). 6. WM_COPYDATA - sending data between windows of different processes. Your question is impossible to answer appropriately without more details. But you might want to read a little bit about each of the technologies mentioned here, and then you can make your own decision.

          0 Offline
          0 Offline
          0v3rloader
          wrote on last edited by
          #4

          Hi Blake and thanks for the input. Looking back at you posted, I think I will have to go for the COM solution as I think it is the best one. Can I ask you one thing though? Do you know of any site(s) with the right technical content I could learn from?

          B 1 Reply Last reply
          0
          • 0 0v3rloader

            Hi Blake and thanks for the input. Looking back at you posted, I think I will have to go for the COM solution as I think it is the best one. Can I ask you one thing though? Do you know of any site(s) with the right technical content I could learn from?

            B Offline
            B Offline
            Blake Miller
            wrote on last edited by
            #5

            I use CodeProject and MSDN almost exclusively. You can post an aritcle request here on CodeProejct, and someone might write a tutorial on COM as it pertains to InterProcess Communications (IPC). I am sorry that I don't have a recommendation for an excellent COM site. Maybe another user here could come up with some suggestions. Also, try the COM forum on CodeProject (unless you already did...)

            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