OLE Samples
The following three samples are the basis for MFC OLE tutorials in Visual C++ Tutorials:
-
The AUTOCLIK sample is the basis for the tutorial on developing an application that supports Automation (formerly OLE Automation).
-
CONTAINER is the basis for the tutorial on developing an ActiveX Visual Editing container application.
-
Step 7 of SCRIBBLE shows how to develop an ActiveX Visual Editing server application.
The TSTCON sample implements an ActiveX control container using MFC's support for OLE embedding. You can use TSTCON to test ActiveX controls, change their properties, and invoke their methods.
The following samples illustrate additional MFC OLE programming techniques not covered in the above tutorials:
-
ACDUAL demonstrates how to add dual interface support to a MFC-based Automation server application.
-
AUTOCLIK Step 4 is a combination ActiveX Visual Editing server and Automation server. Step 4 is not discussed in the tutorial but is discussed here in the sample description.
-
AUTODRIV is a simple Automation client application that drives the AUTOCLIK tutorial sample application. AUTODRIV is also a good demonstration of how to write an Automation driver application.
-
BINDSCRB illustrates the use of new Component Object Model (COM) interfaces to components currently supported by the Microsoft Office suite of products.
-
CALCDRIV is an Automation client application. The description of CALCDRIV includes a procedure that shows how to use the Automation tab in ClassWizard to create dispatch classes from a type library.
-
CONTAINER Step 3 is a combination ActiveX Visual Editing container and Automation client. This version of CONTAINER drives the version Step 4 of AUTOCLIK, the combined ActiveX Visual Editing server and Automation server mentioned above. CONTAINER Step 3 is not discussed in the tutorial but is discussed here in the sample description.
-
DRAWCLI is a full-featured object-oriented drawing application with ActiveX Visual Editing container support. DRAWCLI provides the best illustration of integrating container support with application-specific features — in this case, drawing features. In addition, DRAWCLI demonstrates effective use of C++ object-oriented programming in the design of its "shape" and "drawing tool" classes.
-
GUIDGEN is a simple dialog-based MFC application that can be used to generate globally unique identifiers, or GUIDs, which identify OLE classes, objects, and interfaces.
-
HIERSVR is an ActiveX Visual Editing server application. HIERSVR also uses MFC OLE support for the Clipboard and for drag and drop.
-
INPROC is an in-process Automation server. Unlike the other Automation server samples provided, INPROC can be loaded as a DLL in the client's address space.
-
IPDRIVE is a simple Automation client application that drives the INPROC sample application. IPDRIVE can drive both the in-process version of INPROC as well as the EXE-based or local server version of INPROC, demonstrating the performance advantages of in-process servers.
-
MFCCALC is an Automation server that implements a simple calculator. It can be driven via Automation with the CALCDRIV sample or run stand-alone.
-
MFCBIND shows how to create an ActiveX document (formerly known as a DocObject) container using the ActiveX document container support classes.
-
OCLIENT is an ActiveX Visual Editing container application. It is essentially an extended version of the CONTAINER tutorial sample, which illustrates drag and drop, automatic scrolling during drag-and-drop operations, and Edit Paste Link.
-
SUPERPAD is an ActiveX Visual Editing server application that edits and saves text using the CEditView class.
See Also
Microsoft Foundation Class Library Samples Index