dll question

asad

Member
Apr 28, 2003
56
0
0
hi
i'm a beginner in c++
i would like to know about dll
what does it used for ?
dll and exe what is the difference between them?
thanks in advance
 

calpha

Golden Member
Mar 7, 2001
1,287
0
0
Quick Answer:

EXE = stand alone executable ( as long as you have the requireed libraries registered properly, you can run it)

DLL = Dynamic link library. Written for generic functions that you can use in multiple applications. It's for reusing code you've arleady written.

You have 3 apps you want to write. All of them access a database.

You could:
Write the front end for the three apps.
Write a back end DLL for database access and use that dll in all 3 applications.

 

DaveSimmons

Elite Member
Aug 12, 2001
40,730
670
126
A DLL provides a library of functions that a program can call, often a library that is shared by many different programs. A DLL also lets a company sell a code library without giving away the source code.

Google "what is a DLL" will tell you more. Google is your friend!
 

asad

Member
Apr 28, 2003
56
0
0
scince the dll i created will be only in my pc to invoke it when i need
so any file.exe i creat will not run exept in my pc.
 

Bloodstein

Senior member
Nov 8, 2002
343
0
0
Originally posted by: asad
scince the dll i created will be only in my pc to invoke it when i need
so any file.exe i creat will not run exept in my pc.

Yep...

But if u wanna port ur appl to different pcs, you can always include the dll in the application package :)
 

Descartes

Lifer
Oct 10, 1999
13,968
2
0
Originally posted by: asad
scince the dll i created will be only in my pc to invoke it when i need
so any file.exe i creat will not run exept in my pc.

That entirely depends. You said you invoke it when it's needed, so I'm assuming you're doing a LoadLibrary() instead of linking with the .lib of a DLL. In that case, the user can happily run your application up until they try to execute the code that does a LoadLibrary().