Name Manager
- 3 minutes to read
The Name Manager dialog lists all defined names contained in the workbook and allows end-users to create new names, as well as change and delete existing names.
This dialog is invoked when clicking the Name Manager button on the Formulas ribbon tab. This button is disabled while cell content is being changed. For an example on how to provide your spreadsheet application with a ribbon UI, see the Create a Simple Spreadsheet Application topic.
The Name Manager dialog shows the following information on each defined name.
Dialog Column | Description | API Property |
---|---|---|
Name | A name associated with an individual cell, range of cells, formula or constant. Usually, a name explains the purpose of an object to which this name refers, making it easier to find and use the object. | |
Refers To | A reference to a cell or cell range, formula or constant associated with the defined name. | |
Scope | The scope of the defined name - a worksheet name or “Workbook”. | Worksheet.DefinedNames - worksheet level defined names IWorkbook.DefinedNames - workbook level defined names |
Comment | An explanation or additional information accompanying the defined name. |
Create Names
The New… button in Name Manager invokes the New Name dialog where an end-user can specify all necessary parameters for a new defined name. This dialog is also invoked on clicking the Defined Name button on the Formulas ribbon tab in the Defined Names group.
A new name can be also created via the name box or the Create Names from Selection dialog. However, the New Name dialog gives end-users more flexibility. For example, it allows an end-user to specify any worksheet as the scope of the defined name, or create a comment for the name.
Change Names
An existing defined name can be modified via the Edit Name dialog. It is invoked when an end-user selects a name in the Name Manger dialog and clicks the Edit… button, or double-clicks the name. This dialog allows an end-user to modify the name itself, change the cell reference, formula or constant to which the name refers, or enter a new comment. Only the scope of the defined name cannot be changed.
If DefinedName.RefersTo is the only name parameter required to be changed, an end-user can click the desired name in the Name Manager list and type a new value in the Refers to editor.
To change a cell range associated with a name, an end-user can type a new range reference in the Refers to editor, or click the Collapse Dialog button () and select the desired range directly in the worksheet.
After a new value is entered in the Refers to editor, the Commit () and Cancel () buttons become available to save or cancel the changes.
Delete Names
To delete a defined name from the document, it is necessary to select the name in the Name Manger dialog, and click the Delete button (or press the DELETE key).