Differentiate normal DLL to COM DLL

Answers were Sorted based on User's Feedback



Differentiate normal DLL to COM DLL..

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

Differentiate normal DLL to COM DLL..

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

Differentiate normal DLL to COM DLL..

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

Differentiate normal DLL to COM DLL..

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

Differentiate normal DLL to COM DLL..

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

Differentiate normal DLL to COM DLL..

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

Differentiate normal DLL to COM DLL..

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

Post New Answer

More COM DCOM Interview Questions

What is reference counting in com?

0 Answers  


What kind of components can be used as DCOM servers?

1 Answers  


how to call a dll as a COM dll?

0 Answers  


Can I use .net components from com programs?

0 Answers  


how do you know it is general dll or com dll

5 Answers  






Let?s assume we have object B and aggregated object C (in- proc server), created by B. Can you access any interface of B from C? What?s the difference between aggregated and contained objects?

3 Answers  


How do you make a NET component talk to a COM component?

3 Answers   TCS,


How does a DCOM component know where to instantiate itself?

1 Answers  


Explain JIT activation?

1 Answers  


Suppose we have object b and aggregated object c (in- proc server), created by b. Can you access any interface of b from c? What?s the difference between aggregated and contained objects?

0 Answers  


How to create an instance of the object in COM?

0 Answers  


what is far pointer and what are the use of far poiter in com/dcom ?????

2 Answers   HCL,


Categories