Discusses how to build COM property pages with the Active Template Library. (18 printed pages) Includes a demonstration on how to set some of the properties of a text document within the Microsoft® Visual C++® editor.
Introduction COM property pages provide a user interface for setting the properties (or calling the methods) of one or more COM objects. Property pages are used extensively by Microsoft ActiveX® controls for providing rich user interfaces that allow control properties to be set at design time, but property pages are not limited to that use. For example, many of the tabbed pages displayed as part of the user interface of Microsoft Visual C++ are written as COM property pages, including those displayed by the ATL Object Wizard. COM property pages provide a standard way of allowing a user to configure any COM object, not just controls. As an example, in this article I'll show you how to create a property page that allows the user to set some of the properties of a text document within the Visual C++ editor. First, however, I'll describe how the IPropertyPage interface defines the contract for displaying property pages. I'll show you the sequence of method calls that property page containers make on the interface of a COM property page. Once you understand the essence of the property page contract, I'll move on to show you how the Active Template Library (ATL) provides help for developers creating and using COM property pages. The Property Page Contract Each property page is a COM object that implements the IPropertyPage or IPropertyPage2 interface (see Tables 1 and 2). For simplicity, we'll just consider IPropertyPage in this article.
Author(s): Alex Stockton
Related items:
MSDN site
Remote Data Service in MDAC 2.0
(Kamaljit Bath)