name
How to correct a #NAME? error
Excel for Microsoft 365 Excel for Microsoft 365 for Mac Excel for the web Excel 2021 Excel 2021 for Mac Excel 2019 Excel 2019 for Mac Excel 2016 Excel 2016 for Mac Excel 2013 Excel Web App Excel 2010 Excel 2007 Excel for Mac 2011 Excel Starter 2010 More...Less
The top reason why the #NAME? error appears in the formula is because there is a typo in the formula name. Look at the following example:
Important:The #NAME? error signifies that something needs to be corrected in the syntax, so when you see the error in your formula, resolve it. Do not use any error-handling functions such as IFERROR to mask the error.
To avoid typos in formula names, use the Formula Wizard in Excel. When you start typing a formula name in a cell or the Formula Bar, a list of formulas matching to the words you have entered displays in a dropdown. Once you enter the formula name and the opening parentheses, the Formula Wizard displays the syntax as hover text.
You can also use the Function Wizard to avoid the syntactical errors. Select the cell with the formula, and on the Formula tab, press Insert Function.
Excel will automatically load the Wizard for you.
As you click each argument, Excel will give you the appropriate information for each one.
Given below are other causes of the #NAME? error.
When your formula has a reference to a name that is not defined in Excel, you will see the #NAME? error.
See the following example of a SUM function referring to Profit, which is an undefined name in the workbook.
Solution: Define a name in Name Manager, and then add the name to the formula. Follow these steps to do that:
-
If you already have the data in the spreadsheet, and want to assign a name to specific cells or a cell range, first select the cells in the spreadsheet. If you want to create a new range, you can skip this step.
-
On the Formulas tab, in the Defined Names group, click Define Name, and then click Define Name.
-
Enter a unique name.
-
For the Scope, select if you want the name to be available within the sheet only, or the entire workbook.
-
Enter an optional comment.
-
Click OK.
The next part is to add the name in the formula.
-
Keep the cursor in the formula syntax at the point where you want to add the name you just created.
-
Go to the Formulas tab, in Defined Names group, click Use in Formula, and then select the defined name you want to add.
For more information on using defined names, see Define and use names in formulas.
If the syntax incorrectly refers to a defined name, you will see the #NAME? error.
Continuing with the previous example, a defined name for Profit was created in the spreadsheet. In the following example, the name is not spelled correctly, so the function still throws the #NAME? error.
Solution: Correct the typo in the syntax and retry the formula.
Tip:Instead of manually entering defined names in formulas, you can have Excel do it automatically for you. To do that, go to the Formulas tab, in Defined Names group, click Use in Formula, and then select the defined name you want to add. Excel will add the name to the formula.
When you include text references in formulas, you need to enclose the text in quotation marks, even if you're only using a space. If the syntax omits double quotation marks "" for a text value, you will see the #NAME error. See the following example.
The syntax in this example is missing double quotation marks for has; that's why the error.
Solution: Go back to your syntax and manually inspect to make sure that any text values have quotation marks around them.
If you miss a colon in a range reference, the formula will display a #NAME? error.
In the following example, the INDEX formula throws the #NAME? error because the B2 to B12 range is missing a colon.
Solution: Check your syntax to make sure all range references include the colon.
There are some Excel functions that work only when certain add-ins are enabled. Using these functions otherwise will produce a #NAME? error. For example, to use the EUROCONVERT function, the Euro Currency Tools add-in has to be enabled. If you use custom functions or macros that require the Analysis ToolPak, make sure that the Analysis ToolPak add-in is enabled.
To enable add-ins in Excel:
-
Click File > Options.
-
Click Add-ins.
-
In the Manage list box, pick Excel Add-ins and click Go.
-
Check the relevant box and click OK.
Need more help?
You can always ask an expert in the Excel Tech Community or get support in the Answers community.
See Also
Overview of formulas in Excel
How to avoid broken formulas
Detect errors in formulas
Excel functions (alphabetical)
Excel functions (by category)
Source: https://support.microsoft.com/en-us/office/how-to-correct-a-name-error-b6d54e31-a743-4d7d-9b61-40002a7b4286
0 Response to "name"
Post a Comment