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. Dll pacement

Dll pacement

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

    HI, Is there any restriction that Dll should be in the same folder with Client exe or system folder ? Can i place DLL any where and can Call ? waiting for your precious advice. Thanks, Rayalu

    CPalliniC C 2 Replies Last reply
    0
    • K krishna_CP

      HI, Is there any restriction that Dll should be in the same folder with Client exe or system folder ? Can i place DLL any where and can Call ? waiting for your precious advice. Thanks, Rayalu

      CPalliniC Offline
      CPalliniC Offline
      CPallini
      wrote on last edited by
      #2

      See "Dynamic-Link Library Search Order" at MSDN. :)

      If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
      This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong. -- Iain Clarke
      [My articles]

      In testa che avete, signor di Ceprano?

      1 Reply Last reply
      0
      • K krishna_CP

        HI, Is there any restriction that Dll should be in the same folder with Client exe or system folder ? Can i place DLL any where and can Call ? waiting for your precious advice. Thanks, Rayalu

        C Offline
        C Offline
        Cedric Moonen
        wrote on last edited by
        #3

        Your dll has to be found by your application, which means that it should either be in the system folder or in the same folder of your application. However, if you explicitely load your dll (by using LoadLibrary), you can place it anywhere you want and specify the path of the dll in the call to LoadLibrary.

        Cédric Moonen Software developer
        Charting control [v3.0] OpenGL game tutorial in C++

        CPalliniC K 2 Replies Last reply
        0
        • C Cedric Moonen

          Your dll has to be found by your application, which means that it should either be in the system folder or in the same folder of your application. However, if you explicitely load your dll (by using LoadLibrary), you can place it anywhere you want and specify the path of the dll in the call to LoadLibrary.

          Cédric Moonen Software developer
          Charting control [v3.0] OpenGL game tutorial in C++

          CPalliniC Offline
          CPalliniC Offline
          CPallini
          wrote on last edited by
          #4

          Cedric Moonen wrote:

          However, if you explicitely load your dll (by using LoadLibrary), you can place it anywhere you want and specify the path of the dll in the call to LoadLibrary.

          I think you may do the same thing with implicit loaded DLLs if you specify the path of the dynamic libraries in the application mainifest (anyway I never made a test...). :)

          If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
          This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong. -- Iain Clarke
          [My articles]

          In testa che avete, signor di Ceprano?

          C 1 Reply Last reply
          0
          • CPalliniC CPallini

            Cedric Moonen wrote:

            However, if you explicitely load your dll (by using LoadLibrary), you can place it anywhere you want and specify the path of the dll in the call to LoadLibrary.

            I think you may do the same thing with implicit loaded DLLs if you specify the path of the dynamic libraries in the application mainifest (anyway I never made a test...). :)

            If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.
            This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong. -- Iain Clarke
            [My articles]

            C Offline
            C Offline
            Covean
            wrote on last edited by
            #5

            It also works implicit if you specify the path. I used it to reference to the debug or release version of some dll I wrote, depending on some project setting.

            Greetings Covean

            _ 1 Reply Last reply
            0
            • C Cedric Moonen

              Your dll has to be found by your application, which means that it should either be in the system folder or in the same folder of your application. However, if you explicitely load your dll (by using LoadLibrary), you can place it anywhere you want and specify the path of the dll in the call to LoadLibrary.

              Cédric Moonen Software developer
              Charting control [v3.0] OpenGL game tutorial in C++

              K Offline
              K Offline
              krishna_CP
              wrote on last edited by
              #6

              Thanks Cédric Moonen I did same.

              1 Reply Last reply
              0
              • C Covean

                It also works implicit if you specify the path. I used it to reference to the debug or release version of some dll I wrote, depending on some project setting.

                Greetings Covean

                _ Offline
                _ Offline
                _Superman_
                wrote on last edited by
                #7

                You can also use SetDllDirectory[^] to add a search path to locate the DLL.

                «_Superman_» I love work. It gives me something to do between weekends.
                Microsoft MVP (Visual C++)

                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