hisoka Posted April 7, 2015 Share Posted April 7, 2015 DLL is a library of executable functions or data that can be used by a program . Does not the program has its own functions and data so why it needs exterior functions from DLL application in order to work . I am confused Link to comment Share on other sites More sharing options...
justsomeguy Posted April 7, 2015 Share Posted April 7, 2015 If 20 programs all need to use the same function then it's better to have that function in one place for everything to use instead of writing it in 20 different places. It also makes the functions portable, other programs can open and use DLLs that were originally meant for other programs. Link to comment Share on other sites More sharing options...
hisoka Posted April 7, 2015 Author Share Posted April 7, 2015 what about the DLLs that come with a program when you download it ,from a website , into your computer hard disk . These DLLs are unique to that program . When you delete or uninstall the program these DLLs are deleted or uninstalled with it because they are unique to that program . Why does a program need these DLLs -which are unique to that program and are a libraries or collection of executable functions- if it has its own functions and methods ? Link to comment Share on other sites More sharing options...
justsomeguy Posted April 7, 2015 Share Posted April 7, 2015 If the program gets updated and one (and only one) of those functions has a minor change, should they replace the entire executable or just the one DLL? Link to comment Share on other sites More sharing options...
hisoka Posted April 8, 2015 Author Share Posted April 8, 2015 it is easier to replace only one DLL then the entire program . Until now I understood that DLLs (which are unique to the program) are useful if we want to update a large program . However , I still do not understand what is exactly their role . There are many sites that talk about DLLs but I am unable to discern the role of DLLs and why are they created and why the program needs them Link to comment Share on other sites More sharing options...
justsomeguy Posted April 8, 2015 Share Posted April 8, 2015 However , I still do not understand what is exactly their role .It's right in the name - dynamic linked library. Also known as a shared object. It is code that can be used by any program that links it, that is the role of it. Functions in one place that can be used by anything else. Windows includes hundreds or thousands of them, you can find many of them in the system32 directory. They are there to be used by any program that wants to use those functions. Link to comment Share on other sites More sharing options...
hisoka Posted April 8, 2015 Author Share Posted April 8, 2015 (edited) "It is code that can be used by any program that links it" What does a program link to a DLL mean ? How does a program link to a DLL ? and by which mean or tool? Could not the program immediately access the DLL and use it when needed What is the difference between windows DLLs and the DLLs that come with a program ? why is it called dynamic link library ? why not library ? Edited April 8, 2015 by hisoka Link to comment Share on other sites More sharing options...
justsomeguy Posted April 8, 2015 Share Posted April 8, 2015 How does a program link to a DLL ?The instructions are given in the program's source code to link to a specific DLL and have those functions defined in the program.Could not the program immediately access the DLL and use it when neededThat's what it does.What is the difference between windows DLLs and the DLLs that come with a program ?They just have different functions.why is it called dynamic link library ? why not library ?Because it is dynamically linked, the program links to the file when it actually runs. It is not compiled into the program, it is linked when the program starts running. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now