Thread: including DLL

    #1
  1. Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2003
    Posts
    20
    Rep Power
    0

    including DLL


    I want to include a DLL file in VC++ program but i don't know how to use the different methods of this DLL

    Can u help me ??
  2. #2
  3. No Profile Picture
    Offensive Member
    Devshed Novice (500 - 999 posts)

    Join Date
    Oct 2002
    Location
    in the perfect world
    Posts
    622
    Rep Power
    28
    Implict or Explicit linking?
    Complier and target OS?

    Do you have the library that came with the DLL?
    This lib is used to implicitly link to the dll. That is the dll is loaded at the apps start and if not found the app will fail. A .def file can be used instead.

    Explicit linking is where the DLL is loaded/unloaded as needed and the functions are locked to a pointer using GetProcAddress()

    Do you know the function names and params?
    if not use a dependancy walker.
    The essence of Christianity is told us in the Garden of Eden history. The fruit that was forbidden was on the Tree of Knowledge. The subtext is, All the suffering you have is because you wanted to find out what was going on. You could be in the Garden of Eden if you had just kept your f***ing mouth shut and hadn't asked any questions.

    Frank Zappa
  4. #3
  5. Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2003
    Posts
    20
    Rep Power
    0
    It's an explicit Link.
    I know the differnt functions but I don't know the params.

    What is "dependancy walker"
  6. #4
  7. No Profile Picture
    Offensive Member
    Devshed Novice (500 - 999 posts)

    Join Date
    Oct 2002
    Location
    in the perfect world
    Posts
    622
    Rep Power
    28
    >>I know the differnt functions but I don't know the params.

    So it is not your DLL.
    Will need to find them. Any mistake will stop the linking of the function.

    Is the app and DLL in the same language?

    http://www.dependencywalker.com

    "allows for the discovery of dynamically loaded modules through LoadLibrary() or GetProcAddress() function calls. "
    The essence of Christianity is told us in the Garden of Eden history. The fruit that was forbidden was on the Tree of Knowledge. The subtext is, All the suffering you have is because you wanted to find out what was going on. You could be in the Garden of Eden if you had just kept your f***ing mouth shut and hadn't asked any questions.

    Frank Zappa
  8. #5
  9. Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2003
    Posts
    20
    Rep Power
    0
    The essentiel prob for me is that I want to know how to call the method of the DLL because I find samples in which it calls functions.
    Can u help me for this .
  10. #6
  11. No Profile Picture
    Offensive Member
    Devshed Novice (500 - 999 posts)

    Join Date
    Oct 2002
    Location
    in the perfect world
    Posts
    622
    Rep Power
    28
    Opps wrong thread!
    The essence of Christianity is told us in the Garden of Eden history. The fruit that was forbidden was on the Tree of Knowledge. The subtext is, All the suffering you have is because you wanted to find out what was going on. You could be in the Garden of Eden if you had just kept your f***ing mouth shut and hadn't asked any questions.

    Frank Zappa
  12. #7
  13. Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2003
    Posts
    20
    Rep Power
    0
    and what must I do ?? and what's the problem ??
  14. #8
  15. No Profile Picture
    Offensive Member
    Devshed Novice (500 - 999 posts)

    Join Date
    Oct 2002
    Location
    in the perfect world
    Posts
    622
    Rep Power
    28
    is this mfc?

    have a look at

    AfxLoadLibrary() it has an example of getting the class from a DLL
    The essence of Christianity is told us in the Garden of Eden history. The fruit that was forbidden was on the Tree of Knowledge. The subtext is, All the suffering you have is because you wanted to find out what was going on. You could be in the Garden of Eden if you had just kept your f***ing mouth shut and hadn't asked any questions.

    Frank Zappa

IMN logo majestic logo threadwatch logo seochat tools logo