







 |
|
 The Object
Technology Company
ActiveX Programming in MFC Building
ActiveX Applications in C++
Duration: 4 days
Who should attend?
System architects, Programmer analysts and Software engineers wishing to
add Object Linking and Embedding (ActiveX) features to Windows applications
using Microsoft Foundation Classes.
What will you gain?
- An understanding of the trade-offs involved in using ActiveX and related
technologies,
- A solid foundation of the Common Object Model (COM) philosophy and
architecture, Familiarity with the MFC abstractions for ActiveX programming,
- A tour of the AppWizard-generated code that enables ActiveX containers and
servers.
Course contents and activities:
ActiveX Programming in MFC includes interactive demonstrations to
illustrate effective programming techniques for ActiveX, both via COM and via
MFC. Intensive lab exercises augment the lectures and demos to give the student
a practical understanding of ActiveX programming.
- Course Overview
Audience and background. Instructor introduction. What will we cover,
course layout and structure.
- Introduction to COM
What is the Component Object Model? COM Features. Classes, Objects,
and interfaces. GUID, IUnknown, reference counting, QueryInterface().
Implementing COM objects in C. Implementing COM objects in C++.
Lab: Creating a simple COM DLL.
- Structured Storage
Rationale. Storages and IStorage. IStorage member functions. Streams,
IStream, LockBytes. Compound Files, Transaction Model. Access modes. Creating
and opening a structured storage. Property sets. DocFile Viewer. COleDocument
and COleStreamFile.
Lab: Using structured storage.
- ActiveX and MFC
What MFC brings to ActiveX. Advantages and disadvantages of using MFC
for ActiveX. What the Wizards provide. CCmdTarget. MFC interface maps.
COleObjectFactory.
Lab: Using MFC to produce simple ActiveX application.
- ActiveX user interface
The user model for ActiveX. Linking and embedding. Object states.
Inserting an object. Object transfer model. Object conversion.
- ActiveX containers
Container model. Container responsibilities. Key container/server
interfaces. IOleClientSite, IAdviseSink, IOleObject, IPersistStorage,
IViewObject. MFC ActiveX container classes - COleDocument, CLinkingDoc,
COleClientItem, CRectTracker. AppWizard support for container. AppWizard
generated ActiveX objects. User tasks.
Lab: Writing an ActiveX container.
- Data Storage and Transfer
Need for Uniform Data Transfer. IDataObject. Advise Sinks and
StorageMedia. STGMEDIUM. Formats. IDataObject viewer and demo. MFC
abstractions. Rendering and delayed rendering.
Lab: Data transfer.
- Drag and Drop
Overview of drag and drop. DoDragDrop(), COleDropTarget, and
DROPEFFECT. OnDragOver(), OnDragLeave() and OnDrop(). Implementing a drop
source. Object descriptors.
Lab: Drag and drop.
- ActiveX Servers
ActiveX server concepts. Mini servers and full servers. Registration.
MFC server classes and server utility classes. Server states. Serialization.
COleServerDoc and COleServerItem. COleTemplateServer and COleIPFrameWnd.
AppWizard support for server applications.
Lab: Writing an ActiveX server.
- ActiveX Automation
Why automation? Automation terminology. Automation object.
Automation server and client. Interfaces - IDispatch. DISPID and VARIANTS.
Problems with IDispatch. Type libraries, ODL. ProgID.
Lab: Automation with IDispatch.
- ActiveX Automation with MFC
CCmdTarget support. Dispatch map and dispatch map macros. Creating
IDispatch interfaces. ClassWizard support. Automation clients.
COleDispatchDriver. InvokeHelper(). Strong vs. weak locks. Object lifetime
issues.
Lab: Automation with MFC.
- ActiveX Miscellaneous - Tools Controls, Distributed COM, future
Object Table and Ole2View. CL32TEST and SR32TEST for testing ActiveX
applications. ActiveX Controls. Connection points. Distributed ActiveX.
Marshalling. ActiveX controls. ActiveX, SOM and OpenDoc. ActiveX future -
structured storage changes, compound document changes, ActiveX and ODBC.
- Review and conclusion
This is a lab-intensive course designed to impart expertise in writing
ActiveX applications using COM and MFC. The course combines lectures with
interactive demonstrations of all aspects of ActiveX programming and usage.

Registration |
Calendar | Curriculum
| After Hours | Forms
| Schedules/Pricing
Copyright© Pantheon Systems, Inc. All
rights reserved. |