Skip to content

Latest commit

 

History

History
38 lines (24 loc) · 2.34 KB

File metadata and controls

38 lines (24 loc) · 2.34 KB
title Adding a Control to a Dialog Box (C++)
ms.date 11/04/2016
f1_keywords
vc.editors.dialog.dialog
helpviewer_keywords
dialog boxes [C++], adding controls to
ms.assetid b2a26d19-093f-49ca-93da-fef00dfbb381

Adding a Control to a Dialog Box (C++)

To add a control to a dialog box

  1. Ensure that the dialog box tabbed window is the current document in the editor frame. If a dialog is not the current document, you won't see the Dialog Editor Tab in the Toolbox.

  2. On the Dialog Editor Tab of the Toolbox Window, select the control you want, then:

    • Click the dialog box at the location where you want to place the control. The control appears where you've clicked. For information, see Adding Multiple Controls.

      - or -

    • Drag and drop the control from the Toolbox window to the location on your dialog box. For more information, see Sizing a Control While You Add It.

      - or -

    • Double-click the control in the Toolbox window (it appears on your dialog box) then reposition the control to the location you prefer.

For information about the types of controls available on the Toolbox window, see Dialog Editor Tab, Toolbox Window.

For information on adding resources to managed projects, please see Resources in Desktop Apps in the .NET Framework Developer's Guide. For information on manually adding resource files to managed projects, accessing resources, displaying static resources, and assigning resource strings to properties, see Creating Resource Files for Desktop Apps. For information on globalization and localization of resources in managed apps, see Globalizing and Localizing .NET Framework Applications.

Requirements

Win32

See Also

Controls in Dialog Boxes
Adding Event Handlers for Dialog Box Controls
Dialog Box Controls and Variable Types