Creating an Automation Server

AutoClik: Automation, Lesson 1

Tip   If you prefer working from a printed tutorial, see in MSDN Library Help for details about printing a lesson, a set of topics, or a single topic.

An “Automation server” is an application that exposes programmable objects to other applications, which are called “Automation clients.” This exposure enables clients to “automate” certain functions by directly accessing objects and using the services they provide.

Exposing objects is beneficial when applications provide functionality useful to other applications. For example, a word processor might expose its spell-checking functionality to other programs. Exposure of objects enables vendors to improve their applications by using the ready-made functionality of other applications. In this way, Automation applies some of the principles of object-oriented programming, such as reusability and encapsulation, at the level of applications themselves.

More important is the support Automation provides to users and solution providers. By exposing application functionality through a common, well-defined interface, Automation makes it possible to build comprehensive solutions in a single general programming language, such as Microsoft Visual Basic, instead of in diverse application-specific macro languages.

This tutorial leads you through the basic steps of implementing an Automation server. You will create a simple Automation server application and test it using the Autodriv sample application included with Visual C++.

If you want to learn about implementing an Automation client application, look at the sample application and its description in Samples \ MFC Samples \ MFC OLE Samples in the online documentation.

Note   This tutorial assumes that you are already familiar with the development environment and Visual C++, as well as the basics of the Microsoft Foundation Class Library (MFC). If you are not, complete the Scribble tutorial before you begin this tutorial.

Suggested Reading in Visual C++ Samples