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. call a method in another project

call a method in another project

Scheduled Pinned Locked Moved C / C++ / MFC
questioncsharpc++tutorial
3 Posts 2 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.
  • G Offline
    G Offline
    George Lam
    wrote on last edited by
    #1

    I have a multiple object solution. How do I call from project2 a method in project1? I thought it is project1.method1();. Also, do I need to add header and other stuff to project1 so that it knows how to find method1? If there is some sample code available on line, that would be easiest. The projects are a mixture of C#, C++, and C. I am most interested in the C or C++ angle. I would have search for the solution, but I have no idea what keyword to begin with. Thanks. glam

    G R 2 Replies Last reply
    0
    • G George Lam

      I have a multiple object solution. How do I call from project2 a method in project1? I thought it is project1.method1();. Also, do I need to add header and other stuff to project1 so that it knows how to find method1? If there is some sample code available on line, that would be easiest. The projects are a mixture of C#, C++, and C. I am most interested in the C or C++ angle. I would have search for the solution, but I have no idea what keyword to begin with. Thanks. glam

      G Offline
      G Offline
      George Lam
      wrote on last edited by
      #2

      I meant multiple project solution. glam

      1 Reply Last reply
      0
      • G George Lam

        I have a multiple object solution. How do I call from project2 a method in project1? I thought it is project1.method1();. Also, do I need to add header and other stuff to project1 so that it knows how to find method1? If there is some sample code available on line, that would be easiest. The projects are a mixture of C#, C++, and C. I am most interested in the C or C++ angle. I would have search for the solution, but I have no idea what keyword to begin with. Thanks. glam

        R Offline
        R Offline
        Robert Kuster
        wrote on last edited by
        #3

        > How do I call from project2 a method in project1? In C/C++ CreateRemoteThread should do it. > Also, do I need to add header and other stuff > to project1 so that it knows how to find method1? Simply pass the address of ThreadFunc from project1 to project2 via some kind of IPC (Interprocess Communication). RK

        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