Working With a Defined Name
Posted by:Catalin Bombea | December 14, 2015
What is a Defined Name?
In Excel, you have the option to assign a Name to a cell, or to a Range of cells. This name is reffered to as a Defined Name.A Defined Name will give more flexibility than before, you can refer to it in your formulas, or chart series.Also, the name can be located anywhere in your workbook, you don’t need to use cell or range references.To create a Defined Name,
you have multiple ways:- you can simply right click the cell or the range and select Define Name from the list:
- Or, you can choose Define Name from the Ribbon, from Formulas tab, the Defined Names group:
- Another way to create a Defined Name is to select the range, then simply type into the Name Box the name of your selected range. The Name Box is located to the left of the Formula Bar:
The Scope of a Defined Name:
All Defined Names have a scope, the scope can be:- a specific worksheet (a local name, defined at worksheet level)
- the entire workbook (a workbook name, defined at workbook level).
You Can Edit The Defined Names anytime!
All you have to do is to open the Name Manager, which is located in the same Formulas Tab, Defined Names group: Select the name from the list and click the Edit button, or simply double click the name.Syntax Rules for Defined Names:
The following list of rules is not absolutely necessary to know, but it may be useful to avoid errors when creating new names:- Always make sure that the first character of a name is a letter, an underscore character (_), or a backslash (\). Never start with a number.
- Avoid names that have the same structure as Cell references: AB2355 is not a valid name, for example. Keep in mind that the names are case insensitive, Excel will not make a difference between TotalSales and totalsales
- Do not use Spaces, always use an underscore characterΒ (_) or a period character (.) as a word delimiter! Or, just start the name with uper case letters, like: TotalSales
- A name can contain up to 255 characters. For me, is far more than necessary, I prefer short and meaningful names π