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. Saving data between DLL calls

Saving data between DLL calls

Scheduled Pinned Locked Moved C / C++ / MFC
question
6 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
    DarrollWalsh
    wrote on last edited by
    #1

    Is there a way to save information between function calls when using load library? I can always use a file on the drive, or redefine my function params, just curious. Darroll Not one person lives in the present. Only the past. I can prove it.

    C 1 Reply Last reply
    0
    • D DarrollWalsh

      Is there a way to save information between function calls when using load library? I can always use a file on the drive, or redefine my function params, just curious. Darroll Not one person lives in the present. Only the past. I can prove it.

      C Offline
      C Offline
      Chris Losinger
      wrote on last edited by
      #2

      a global variable in a DLL will persist until your app releases the DLL. -c


      All you have to do is tell the people they are being attacked, and denounce the opposition for lack of patriotism and exposing the country to danger. -- Herman Goering

      War Pigs

      D 1 Reply Last reply
      0
      • C Chris Losinger

        a global variable in a DLL will persist until your app releases the DLL. -c


        All you have to do is tell the people they are being attacked, and denounce the opposition for lack of patriotism and exposing the country to danger. -- Herman Goering

        War Pigs

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

        That would be a prob as I release the dll every time I call the function. It is a plugin. Is that the only way? Darroll Not one person lives in the present. Only the past. I can prove it.

        C 1 Reply Last reply
        0
        • D DarrollWalsh

          That would be a prob as I release the dll every time I call the function. It is a plugin. Is that the only way? Darroll Not one person lives in the present. Only the past. I can prove it.

          C Offline
          C Offline
          Chris Losinger
          wrote on last edited by
          #4

          Darroll wrote: Is that the only way? maybe not the only way, but it's the obvious way :) for plugins, i always write the data to a file somewhere (or the registry, depending on my mood). -c


          All you have to do is tell the people they are being attacked, and denounce the opposition for lack of patriotism and exposing the country to danger. -- Herman Goering

          War Pigs

          D 1 Reply Last reply
          0
          • C Chris Losinger

            Darroll wrote: Is that the only way? maybe not the only way, but it's the obvious way :) for plugins, i always write the data to a file somewhere (or the registry, depending on my mood). -c


            All you have to do is tell the people they are being attacked, and denounce the opposition for lack of patriotism and exposing the country to danger. -- Herman Goering

            War Pigs

            D Offline
            D Offline
            DarrollWalsh
            wrote on last edited by
            #5

            My next thought is how to know when the app starts as to not save data between sessions. I may have to have the app set a running flag in the registry or something. If there is an easier way then this. Any clues? Darroll Not one person lives in the present. Only the past. I can prove it.

            C 1 Reply Last reply
            0
            • D DarrollWalsh

              My next thought is how to know when the app starts as to not save data between sessions. I may have to have the app set a running flag in the registry or something. If there is an easier way then this. Any clues? Darroll Not one person lives in the present. Only the past. I can prove it.

              C Offline
              C Offline
              Chris Losinger
              wrote on last edited by
              #6

              you could use a mutex, but a reg key might be just as easy. -c


              All you have to do is tell the people they are being attacked, and denounce the opposition for lack of patriotism and exposing the country to danger. -- Herman Goering

              War Pigs

              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