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 / C++ / MFC
  4. DLL Importing a class from the calling EXE

DLL Importing a class from the calling EXE

Scheduled Pinned Locked Moved C / C++ / MFC
salesperformancehelpquestion
4 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.
  • D Offline
    D Offline
    DKScherpy
    wrote on last edited by
    #1

    I've got a problem with a DLL calling a function from a class in the EXE. Here's the scenario I have. My app needs to give the user the a certain ability if and only if the DLL is present on their machine. (In this case it is a DLL I wrote to print a custom report). So if the DLL exists, when the report is called, the exe passes the object to make the report from to the DLL and the DLL goes to work and make the report. What I need to be able to do, is to support the object changing in the EXE (new functions, new class members - basically, to be able to change the memory map of the object) and for the DLL (even if it is 3 generations older than the calling EXE) to still take in the object and create the report. This way, the customer can just keep their original custom DLL but still get updates to the product. Anybody know a way to do this? Thanks Dave

    L 1 Reply Last reply
    0
    • D DKScherpy

      I've got a problem with a DLL calling a function from a class in the EXE. Here's the scenario I have. My app needs to give the user the a certain ability if and only if the DLL is present on their machine. (In this case it is a DLL I wrote to print a custom report). So if the DLL exists, when the report is called, the exe passes the object to make the report from to the DLL and the DLL goes to work and make the report. What I need to be able to do, is to support the object changing in the EXE (new functions, new class members - basically, to be able to change the memory map of the object) and for the DLL (even if it is 3 generations older than the calling EXE) to still take in the object and create the report. This way, the customer can just keep their original custom DLL but still get updates to the product. Anybody know a way to do this? Thanks Dave

      L Offline
      L Offline
      led mike
      wrote on last edited by
      #2

      DKScherpy wrote:

      Anybody know a way to do this?

      You mean using an "Interface"?

      led mike

      D 1 Reply Last reply
      0
      • L led mike

        DKScherpy wrote:

        Anybody know a way to do this?

        You mean using an "Interface"?

        led mike

        D Offline
        D Offline
        DKScherpy
        wrote on last edited by
        #3

        Possibly - I kind of understand what an interface is/works. Can you, or anyone, give me a link or source that I can find an example of? -- modified at 9:06 Friday 15th December, 2006

        L 1 Reply Last reply
        0
        • D DKScherpy

          Possibly - I kind of understand what an interface is/works. Can you, or anyone, give me a link or source that I can find an example of? -- modified at 9:06 Friday 15th December, 2006

          L Offline
          L Offline
          led mike
          wrote on last edited by
          #4

          DKScherpy wrote:

          Can you, or anyone, give me a link or source that I can find an example of?

          You should try looking at the "Articles" here on Code Project. They are a great resource. Using Interfaces in C++[^]

          led mike

          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