Skip to content

Latest commit

 

History

History
31 lines (21 loc) · 2.15 KB

adding-an-atl-dialog-box.md

File metadata and controls

31 lines (21 loc) · 2.15 KB
description title ms.date helpviewer_keywords ms.assetid
Learn more about: Adding an ATL Dialog Box
Adding an ATL Dialog Box
11/04/2016
ATL projects, adding dialog resources
MFC dialog boxes, ATL dialogs
dialog boxes, ATL
152a378f-7b24-4f66-aeba-c740973f03a6

Adding an ATL Dialog Box

To add an ATL dialog to your project, your project must be either an ATL project or an MFC project that includes ATL support. You can use the ATL Project Wizard to create an ATL application, or add an ATL object to your MFC application to implement ATL support for an MFC application.

By default, the ATL Dialog Wizard implements a dialog box derived from CAxDialogImpl. This class includes support for hosting ActiveX and Windows controls. If you do not want the overhead of ActiveX control support, once the wizard has generated your code, replace all instances of CAxDialogImpl with either CSimpleDialog or CDialogImpl as your base class.

Note

CSimpleDialog creates only modal dialog boxes that support only Windows common controls. CDialogImpl creates either modal or modeless dialog boxes.

To add an ATL dialog resource to your project

  1. Create an ATL project using the ATL Project Wizard.

  2. From Class View, right-click the project name and click Add from the shortcut menu. Click Add Class.

  3. In the Templates pane of the Add Class dialog box, click ATL Dialog. Click Open to display the ATL Dialog Wizard.

For more information, see Implementing a Dialog Box.

See also

Adding a Class
Window Classes
Message Maps