Differentiate normal DLL to COM DLL
Answers were Sorted based on User's Feedback
Answer / riddhi
COM Dll exposes Interface on the contrary to normal DLL
that exports functions. Clients create the pointer to
COMDLL's interface to call the methods defined by the
component that implements the interface.
That results in isolation of implementation and definition
of method in the interface. Client doesnt need to relink or
recompile the code if method in the com dll changes as far
as the definition of the interface remains same.
Is This Answer Correct ? | 19 Yes | 3 No |
Answer / vijay kumar bhatia
2nd answer is correct. Also following differences can be
added
COM DLL is registerable dll while normal is non-registerable
COM DLL only exports following 4 functions
* DllGetClassObject.
* DllRegisterServer.
* DllUnregisterServer.
* DllCanUnloadNow
Is This Answer Correct ? | 9 Yes | 2 No |
Answer / sunil choubey
COM DLL has to implement at least IUnknown inteface, however this is not the restriction of regulare DLL.
You have to register COM DLL by using regsvr32 utility, and its information is store in windows registry, this is not in case of normal DLL.
You have to put normal dll in path or current directory, but not in case of COM DLL.
You can use COM DLL in any language, but if you want to do it with normal dll then you have to export plan function, this should not be Object Oriented. If you try to export classes from normal DLL or make MFC extension then you cant use it in VB and scripting language like VB Script.
By making COM DLL you have to export its interface and write it in IDL file and in case of normal DLL you do it either in DEF file or using _declspec(export) with function or class name.
Is This Answer Correct ? | 1 Yes | 0 No |
Answer / elangovv
To add with the answer 2 and 4. In COM dll we can implement
the OOP's concepts were as in regular DLL it is not
possible. Like encapsulation, inheritance, polymorphism ect...
Is This Answer Correct ? | 1 Yes | 2 No |
Answer / pranesh archak
A normal DLL can export any function.
A COM DLL is the one which exports COM APIs like
* DllGetClassObject.
* DllRegisterServer.
* DllUnregisterServer.
* DllCanUnloadNow.
Is This Answer Correct ? | 6 Yes | 9 No |
Answer / saravanan k
Classic DLLs are function libraries while ActiveX(COM)
DLLs are objects. The difference is like the difference
between procedural and object oriented programming.
API style Declare statements are needed for routines in
a 'normal' DLL and and an ActiveX(COM) DLL is treated like a
class object.
Is This Answer Correct ? | 2 Yes | 5 No |
Answer / krishna s
classic DLLs are not platform independent, can export
functions, classes(only MFC application can import these
classes).
Need to remember location of the DLL before loading.
Where as COM is platform indenpendent.
No need to remember the COM DLL location for loading
instead need to register using regsvr32 utility.
Is This Answer Correct ? | 1 Yes | 4 No |
Do COM keep track of all the object references(Accounting)?
How do we create dcom object in vb6?
where can i use pmcmd commands of informatica
What is a moniker ?
What should QueryInterface functions do if requested object was not found?
How to create an instance of the object in COM?
What happens when client calls CoCreateInstance?
Differentiate normal DLL to COM DLL
Can I use com components from .net programs?
Explain transaction atomicity?
Define and explain COM?
C is aggregated by B, which in turn aggregated by A. Our client requested C. What will happen?