Click here to Skip to main content
14,212,177 members
Click here to Skip to main content

Stats

712.5K views
4.5K downloads
436 bookmarked

Understanding The COM Single-Threaded Apartment Part 1

,
Rate this:
4.95 (201 votes)
Please Sign up or sign in to vote.
4.95 (201 votes)
6 Jan 2005     CPOL    
Learn the fundamental principles of the COM Single-Threaded Apartment Model by code examples.
LegacyCOMObject1
Shared
SimpleCOMObject1
SimpleCOMObject2
Test Programs
LegacyCOMObject1.def
LegacyCOMObject1.dsp
LegacyCOMObject1.dsw
LegacyCOMObject1.rgs
LegacyCOMObject1.tlb
LegacyCOMObject1ps.def
SimpleCOMObject1.def
SimpleCOMObject1.dsp
SimpleCOMObject1.dsw
SimpleCOMObject1.rgs
SimpleCOMObject1.tlb
SimpleCOMObject1ps.def
SimpleCOMObject2.def
SimpleCOMObject2.dsp
SimpleCOMObject2.dsw
SimpleCOMObject2.rgs
SimpleCOMObject2.tlb
SimpleCOMObject2ps.def
VBTest
VCTests
MSSCCPRJ.SCC
VBTest.exe
VBTest.vbp
VBTest.vbw
DemonstrateDefaultSTA
DemonstrateExeServerSTA
DemonstrateLegacySTA
DemonstrateNoMessageLoop
DemonstrateSTA
VCTest01
VCTest02
SimpleCOMObject2.tlh
SimpleCOMObject2.tli
VCTest01.dsp
VCTest01.dsw
SimpleCOMObject2.tlh
SimpleCOMObject2.tli
VCTest02.dsp
VCTest02.dsw
Client
Implementation
Interface
VCTest01
VCTest01.dsp
VCTest01.dsw
ExeServerImpl
ExeServerImpl.dsp
ExeServerImpl.dsw
REGISTRY.CPP
REGISTRY.H
ExeServerInterfaces
ExeObj01.rgs
ExeObj02.rgs
ExeObj03.rgs
ExeServerInterfaces.def
ExeServerInterfaces.dsp
ExeServerInterfaces.dsw
ExeServerInterfaces.tlb
ExeServerInterfacesps.def
VCTest01
VCTest02
LegacyCOMObject1.tlh
LegacyCOMObject1.tli
VCTest01.dsp
VCTest01.dsw
VCTest02.dsp
VCTest02.dsw
VCTest01
SimpleCOMObject2.tlh
SimpleCOMObject2.tli
VCTest01.dsp
VCTest01.dsw
VCTest01
SimpleCOMObject2.tlh
SimpleCOMObject2.tli
VCTest01.dsp
VCTest01.dsw
/* this file contains the actual definitions of */
/* the IIDs and CLSIDs */

/* link this file in with the server and any clients */


/* File created by MIDL compiler version 5.01.0164 */
/* at Thu Dec 23 00:02:07 2004
 */
/* Compiler settings for C:\Limbl\Develope\CodeProject\CCOMThread\LegacyCOMObject1\LegacyCOMObject1.idl:
    Oicf (OptLev=i2), W1, Zp8, env=Win32, ms_ext, c_ext
    error checks: allocation ref bounds_check enum stub_data 
*/
//@@MIDL_FILE_HEADING(  )
#ifdef __cplusplus
extern "C"{
#endif 


#ifndef __IID_DEFINED__
#define __IID_DEFINED__

typedef struct _IID
{
    unsigned long x;
    unsigned short s1;
    unsigned short s2;
    unsigned char  c[8];
} IID;

#endif // __IID_DEFINED__

#ifndef CLSID_DEFINED
#define CLSID_DEFINED
typedef IID CLSID;
#endif // CLSID_DEFINED

const IID IID_ILegacyCOMObject1 = {0x2E85D9EA,0x84E5,0x4767,{0x80,0x10,0x64,0x00,0xBA,0x59,0xCD,0xBF}};


const IID LIBID_LEGACYCOMOBJECT1Lib = {0x6934F572,0x21B7,0x43DE,{0xBD,0xCD,0xB9,0x09,0xDA,0x3C,0x57,0x2B}};


const IID DIID__ILegacyCOMObject1Events = {0xF82638B5,0x058B,0x46EE,{0x95,0xD7,0x98,0x8A,0xF1,0x5A,0x69,0x4E}};


const CLSID CLSID_LegacyCOMObject1 = {0x81A0A4E9,0xF514,0x4932,{0x95,0xAA,0x63,0x2F,0x76,0x74,0x29,0xE6}};


#ifdef __cplusplus
}
#endif

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Lim Bio Liong
Systems Engineer NEC
Singapore Singapore
Lim Bio Liong is a Specialist at a leading Software House in Singapore.

Bio has been in software development for over 10 years. He specialises in C/C++ programming and Windows software development.

Bio has also done device-driver development and enjoys low-level programming. Bio has recently picked up C# programming and has been researching in this area.

Layout: fixed | fluid

Article Copyright 2005 by Lim Bio Liong
Everything else Copyright © CodeProject, 1999-2019

Server Web01
Version 2.8.190619.2