When Kenobewan said to learn the fundamentals, he was right, though, he could have added what you (and others here) need to learn.

1 - There are different types of memory, CODE, DATA, STACK, DYNAMIC (HEAP).

2 - DLL's are used for CODE sharing (so the same code being used by several applications, is not loaded multiple times by the O/S). DLL's are not for sharing DATA across applications (though, within an app, one can share...