Skip to main content

How to highlight all named ranges in Excel?

Author Xiaoyang Last modified

Named ranges in Excel provide a convenient way to reference specific cells or ranges using meaningful names instead of cell addresses. However, if your spreadsheet contains multiple named ranges, locating them all can be a challenge. This article outlines several efficient methods to highlight all named ranges in Excel.

Highlight all named ranges in a workbook with VBA code

Highlight all named ranges in a workbook with Kutools for Excel


Highlight all named ranges in a workbook with VBA code

Here is a code to highlight all the named ranges in a workbook, you can do as this:

1. Hold down the "ALT + F11" keys, and it opens the "Microsoft Visual Basic for Applications" window.

2. Click "Insert" > "Module", and paste the following code in the Module Window.

VBA code: Highlight all named ranges in Excel

Sub HighlightRange()
'Updateby Extendoffice
Dim xName As Name
Dim Rng As Range
On Error Resume Next
For Each xName In Application.ActiveWorkbook.Names
    Set Rng = xName.RefersToRange
    Rng.Interior.ColorIndex = 6
Next
End Sub

3. Then press F5 key to execute this code, and all the named ranges have been highlighted with yellow color in the whole workbook.

Notes:
  1. If you want to fill the named ranges with other colors, you just need to change the color number within the "ColorIndex = 6" script.
  2. After applying this code, all the original color in the named ranges are canceled and covered by this new color.

Highlight all named ranges in a workbook with Kutools for Excel

Kutools for Excel offers a powerful "Highlight Names" feature that allows users to quickly identify all named ranges dynamically. Unlike traditional methods, this feature automatically updates the highlighting when new named ranges are added or existing ones are removed, ensuring real-time visibility.

Kutools for Excel offers over 300 advanced features to streamline complex tasks, boosting creativity and efficiency. Itegarate with AI capabilities, Kutools automates tasks with precision, making data management effortless. Detailed information of Kutools for Excel...         Free trial...

After installing Kutools for Excel, please do as this:

1. Click "Kutools Plus" > "Design View", see screenshot:
go to click Desin View command

2. In the opened "Kutools Design" tab, Click "Highlight Names", see screenshot:
go to click Highlight Nmaes feature

Now, all named ranges in the entire workbook are highlighted simultaneously. If new named ranges are added or existing ones are removed, the highlighting updates dynamically to reflect these changes.

Note:
  • Click the "Highlight Names" again, the highlight color will be canceled at once.

By using VBA code or the Kutools for Excel tool, users can easily highlight all named ranges in a workbook. Regardless of the chosen method, both tools effectively help users quickly identify and manage named ranges in a workbook, enhancing work efficiency and data readability. If you're interested in exploring more Excel tips and tricks, our website offers thousands of tutorials to help you master Excel.


Related articles:

How to highlight all subtotal rows at once in Excel?

How to highlight all error cells in Excel?

How to highlight cells with external links in Excel?


Best Office Productivity Tools

🤖 Kutools AI Aide: Revolutionize data analysis based on: Intelligent Execution   |  Generate Code  |  Create Custom Formulas  |  Analyze Data and Generate Charts  |  Invoke Kutools Functions
Popular Features: Find, Highlight or Identify Duplicates   |  Delete Blank Rows   |  Combine Columns or Cells without Losing Data   |   Round without Formula ...
Super Lookup: Multiple Criteria VLookup    Multiple Value VLookup  |   VLookup Across Multiple Sheets   |   Fuzzy Lookup ....
Advanced Drop-down List: Quickly Create Drop Down List   |  Dependent Drop Down List   |  Multi-select Drop Down List ....
Column Manager: Add a Specific Number of Columns  |  Move Columns  |  Toggle Visibility Status of Hidden Columns  |  Compare Ranges & Columns ...
Featured Features: Grid Focus   |  Design View   |   Big Formula Bar    Workbook & Sheet Manager   |  Resource Library (Auto Text)   |  Date Picker   |  Combine Worksheets   |  Encrypt/Decrypt Cells    Send Emails by List   |  Super Filter   |   Special Filter (filter bold/italic/strikethrough...) ...
Top 15 Toolsets12 Text Tools (Add Text, Remove Characters, ...)   |   50+ Chart Types (Gantt Chart, ...)   |   40+ Practical Formulas (Calculate age based on birthday, ...)   |   19 Insertion Tools (Insert QR Code, Insert Picture from Path, ...)   |   12 Conversion Tools (Numbers to Words, Currency Conversion, ...)   |   7 Merge & Split Tools (Advanced Combine Rows, Split Cells, ...)   |   ... and more
Use Kutools in your preferred language – supports English, Spanish, German, French, Chinese, and 40+ others!

Supercharge Your Excel Skills with Kutools for Excel, and Experience Efficiency Like Never Before. Kutools for Excel Offers Over 300 Advanced Features to Boost Productivity and Save Time.  Click Here to Get The Feature You Need The Most...


Office Tab Brings Tabbed interface to Office, and Make Your Work Much Easier

  • Enable tabbed editing and reading in Word, Excel, PowerPoint, Publisher, Access, Visio and Project.
  • Open and create multiple documents in new tabs of the same window, rather than in new windows.
  • Increases your productivity by 50%, and reduces hundreds of mouse clicks for you every day!