COM in C#
COM stands for "Common object modal".
com is a kind of specification to make the component reusable. All the active components are by default com components. com is a concept-its practical implementation is activex.
========= ABOVE CONCEPT WAS USED IN VB/VC++/C++=========
In .NET for this purpose we use assembly
Assembly is the component modal for .NET.
1. It contains the meta data (data about data).
2. Project details: Name/version/author/creation date/creation time/ and
IL (Intermediate language).
Assembly have two parts:
1. Manifest : Name, Author, Creation date, Time.
2. Body : IL
To view assembly: C:\>ILDASM A.EXE
Types of assembly
1. Private assembly:for same project
2. Public or shared assembly:for any project
Assembly comes in the form of
.DLL (Dynamic link library)
.EXE (Executable file)
Difference between .dll & .exe
1. Not self executed
1. Self executable
2. No Main()
3. In Process
3. Out Process
(Execute in client memory)
(Hold separate memory)
4. light weight
4. heavy weight
How to make a .dll :
1.Class library : There will be Class(
2. Window control library : There will be user defined control.
How to make a class library
1. Open visual studio-->File menu- select new project- select C# class
library-name-location then OK.
3. Build (After that .dll will create)
Windows control library
1. Open visual studio -File menu-new project -C#-windows form control
Example: Digital clock
Take label and timer form Toolbox.
3. Bulid solution