• Link to Facebook
  • Link to Youtube
  • Link to LinkedIn
  • Link to X
  • Link to Tiktok
  • Link to Instagram
  • EN ESPAÑOL
    • Inicio
    • Glosario de Términos
    • Modelos Financieros
    • Tutoriales Cortos
  • A.CRE HELP
    • Support Section
    • Contact Us
  • LOGIN/REGISTER
  • Shopping Cart Shopping Cart
    0Shopping Cart
Adventures in CRE
  • A.CRE
    • A.CRE Home
    • A.CRE Help
    • Accelerator
      • Learn More
      • Login
    • AI.Edge
      • Learn More
      • Login
    • Artificial Intelligence
    • Careers
    • CRE Event Calendar
    • CRE Job Board
    • Education
    • Library of Excel Models
    • Meet the A.CRE Team
  • RE Modeling
    • 1031 Exchange
    • Audio Series
    • All-in-One (Ai1) Model
      • Download
      • Guides and Tutorials
      • Support
    • Ask Me Anything (Live)
    • Beginner’s Guide to Excel
    • Excel Models
      • Excel Add-ins
      • Library of Excel Models
      • All-in-One (Ai1) Model
      • Apartment
      • Condo
      • Debt
      • Development
      • Equity Waterfall
      • Hotel
      • Industrial
      • Office
      • Portfolio
      • Retail
      • Single Family
      • Tutorial
    • Excel Tips
    • Practice Library of Case Studies
    • Stochastic Modeling
    • Argus
    • My Downloads / My Account
  • Careers
    • About Careers in Real Estate
    • Ask Me Anything (Live)
    • Audio Series
    • Compensation in Real Estate
    • CRE Job Board
      • Find a Job
        • Browse Jobs
        • Post a Resume
        • Register
        • Login
      • Post a Job
    • CRE Event Calendar
    • CRE Interviews
    • Day in the Life Series
    • Real Estate Legal Content
    • What CRE Pros Do
  • Education
    • Accelerator
    • AI.Edge
    • A.CRE 101
    • Ask Me Anything (Live)
    • A.CRE Audio Series
    • Audio Series
    • Book Reviews
    • CRE Event Calendar
    • Deep Dive Series
    • Glossary of CRE Terms
    • Real Estate Legal Content
    • Real Estate Clubs
    • University Profiles
    • Watch Me Build
  • AI
    • AI Skills
    • AI Use Cases in CRE
    • AI for CRE Training
    • AI Tools for CRE
    • AI.Edge Membership
      • Learn More
      • Login
  • Accelerator
    • Accelerator Reviews
    • Accelerator Story
    • Enroll Now
    • Learn More
    • See What’s New
    • Enterprise Members Only
      • General Enterprise Login
      • ICSC Login
      • M&M Login
    • Members Only
      • Extend/Renew Membership
      • Login
      • Manage Membership
  • My Downloads
    • View My Downloads
    • Find an Excel Model
    • Register
    • Login
  • Click to open the search input field Click to open the search input field Search
  • Menu Menu
You are here: Home1 / Real Estate Financial Modeling2 / Excel Tips3 / Hide and Unhide Tabs using Drop-down Menus in Excel (Updated Apr 2024)
Spencer Burton
Real Estate Financial Modeling, Excel Tips, Excel Models, Tutorial

Hide and Unhide Tabs using Drop-down Menus in Excel (Updated Apr 2024)

I’d like to share a handy little trick I learned this week for hiding and unhiding tabs in Excel using drop-down menus. Now this method requires you to use some basic VBA code and to save the Workbook as a Macro-Enabled file but don’t be intimidated – no previous coding experience is required to make this work. I’ve recorded a short video tutorial that walks you through the process and included the VBA code you will need below. I’ve also added a download link to the Excel file used in this tutorial.

  • Are you an Accelerator member? Check out other Excel tutorials like this one in our Mastering MS Excel for Real Estate Endorsement. Not yet an Accelerator member? Consider joining our A.CRE Accelerator, the industry’s preeminent real estate financial modeling training program.

Why Add this to my Real Estate Model?

If you’ve spent much time working with real estate financial models, you’ve probably come across a model with way too many tabs. Perhaps it’s a portfolio model with tabs for dozens of properties, or a complex DCF with a multitude of behind-the-scenes calculation tabs. Whatever the reason, having a lot of tabs in your model can kill the user experience. This trick will allow you, the creator of the model, to determine which tabs are visible based on criteria selected by the user.

So, for instance, imagine you build a portfolio model for up to 30 properties with one tab for each property. You then add a drop-down menu on your summary tab where the user can select the number of properties in the portfolio. If the user selects 12 for example, 12 property tabs are left visible and 18 property tabs are automatically hidden from view. If the user wants to add more properties, she simply chooses more properties from the drop-down menu and the relevant tabs automatically become visible.

  • Quick Tip: If you have our (free) ‘Excel 4 CRE’ add-in installed, you can ‘unhide all worksheets’ by simply clicking ‘Ctrl+Shift+?‘.

Step-by-Step Video Tutorial – Hide and Unhide Worksheets

In this video tutorial, I walk you step-by-step through the process of creating a feature to hide and unhide worksheets from a dropdown menu.

The VBA Code

Here is a template of the VBA code used in the video. Replace the text in blue with text specific to your model.

Private Sub Worksheet_Change(ByVal Target As Range)

If [CELL NAME] = “SOME VALUE” Then
Sheets(“TAB NAME“).Visible = False
Else
Sheets(“TAB NAME“).Visible = True
End If

End Sub

The Holy Grail Has Arrived – AI as Our Personal VBA Developer

Since creating this tutorial, a monumental tool has arrived that greatly simplifies projects such as this: large language models (or LLMs). As of 2024, the most used LLMs include OpenAI’s GPT-x (i.e. ChatGPT), Gemini, Claude, Llama, etc. These language models are more than capable of instantly writing virtually any VBA code you might need in real estate financial modeling.

For instance, if I ask Gemini the following: “please provide step-by-step logic, instructions, and VBA code in order to hide and unhide certain worksheets based on a given dropdown menu”, the AI returns instructions similar to what I shared above together with this VBA code:

Sub Worksheet_Visibility()
Dim selectedOption As String
Dim ws As Worksheet

‘ Get the selected option from the dropdown
selectedOption = Sheets(“ControlSheet”).Range(“A1”).Value ‘ Adjust cell reference if needed

‘ Loop through all worksheets
For Each ws In ThisWorkbook.Worksheets
Select Case selectedOption
Case “DataSheet1”
ws.Visible = IIf(ws.Name = “DataSheet1”, xlSheetVisible, xlSheetVeryHidden)
Case “DataSheet2”
ws.Visible = IIf(ws.Name = “DataSheet2”, xlSheetVisible, xlSheetVeryHidden)
Case “Show All”
ws.Visible = xlSheetVisible
Case Else
‘ Do nothing if no match
End Select
Next ws
End Sub

With this new AI tech, anyone – regardless of coding capability – is able to create virtually any custom Excel functionality they might imagine. It’s quite extraordinary! I highly recommend becoming proficient using LLMs and using them to craft VBA code for yourself.

By the way, we’re having a ton of fun at A.CRE playing around with this tech. If you haven’t already, browse the various applications for AI in commercial real estate that we’ve been exploring.

Compatibility

This version of the model is only compatible with Excel 2013, Excel 2016, and Excel 365.

Download the Hide and Unhide Tabs Using Drop-Down Menus In Excel Tool

To make this tool accessible to everyone, it is offered on a “Pay What You’re Able” basis with no minimum (enter $0 if you’d like) or maximum (your support helps keep the content coming – typical real estate tools sell for $25- $100+ per license). Just enter a price together with an email address to send the download link to, and then click ‘Continue’. If you have any questions about our “Pay What You’re Able” program or why we offer our models on this basis, please reach out to either Mike or Spencer.

We regularly update the tool (see version notes). Paid contributors to the tool receive a new download link via email each time the tool is updated.

Proceed to Download Page

Frequently Asked Questions about Hiding and Unhiding Tabs Using Drop-Down Menus in Excel

Why use drop-down menus to hide/unhide tabs in Excel?

Using drop-downs to hide/unhide tabs improves user experience in complex models, especially those with many sheets. It lets users reveal only the necessary tabs—like selecting how many properties are in a portfolio—keeping the workbook clean and navigable.

What kind of Excel file do I need to use this feature?

You must save your Excel file as a Macro-Enabled Workbook (.xlsm) in order to use the VBA code that drives the hide/unhide functionality.

What VBA code is needed to hide/unhide tabs based on a drop-down?

You can use either the simpler Worksheet_Change event:

vba
Copy
Edit
Private Sub Worksheet_Change(ByVal Target As Range)
If [CELL NAME] = “SOME VALUE” Then
Sheets(“TAB NAME”).Visible = False
Else
Sheets(“TAB NAME”).Visible = True
End If
End Sub
Or use the full macro approach shown in the tutorial:

vba
Copy
Edit
Sub Worksheet_Visibility()
Dim selectedOption As String
Dim ws As Worksheet

selectedOption = Sheets(“ControlSheet”).Range(“A1”).Value

For Each ws In ThisWorkbook.Worksheets
Select Case selectedOption
Case “DataSheet1”
ws.Visible = IIf(ws.Name = “DataSheet1”, xlSheetVisible, xlSheetVeryHidden)
Case “DataSheet2”
ws.Visible = IIf(ws.Name = “DataSheet2”, xlSheetVisible, xlSheetVeryHidden)
Case “Show All”
ws.Visible = xlSheetVisible
Case Else
‘ Do nothing
End Select
Next ws
End Sub

Do I need coding experience to set this up?

No prior coding experience is needed. The tutorial includes step-by-step guidance and ready-to-paste VBA code. Plus, tools like ChatGPT can generate or modify the code for you using plain language instructions.

Can I unhide all tabs quickly without a macro?

Yes. If you have the free “Excel 4 CRE” add-in installed, you can unhide all tabs by pressing Ctrl + Shift + ?.

What Excel versions are compatible with this tool?

This macro-enabled feature is compatible with Excel 2013, Excel 2016, and Excel 365.

Where can I download the example workbook?

You can download the Hide/Unhide Tabs Excel tool from the A.CRE website on a “Pay What You’re Able” basis. Enter your email and contribution (optional) to receive the file download link.

How can AI tools like GPT help me with VBA?

AI tools like OpenAI’s GPT can write complete VBA macros based on natural language instructions. For example, you can ask for “a macro that hides tabs based on a dropdown” and the AI will generate the needed code—great for those without coding backgrounds.


Version Notes

v1.1

  • Updates to Version tab
  • Cleaned up tab color formatting
  • Misc worksheet formatting updates

v1.0

  • Initial release

About the Author: Spencer Burton is Co-Founder and CEO of CRE Agents, an AI-powered platform training digital coworkers for commercial real estate. He has 20+ years of CRE experience and has underwritten over $30 billion in real estate across top institutional firms.

Spencer also co-founded Adventures in CRE, served as President at Stablewood, and holds a BS in International Affairs from Florida State University and a Masters in Real Estate Finance from Cornell University.

Contact Spencer
by Spencer Burton
Share this entry
  • Share on X
  • Share on LinkedIn
  • Share by Mail
  • Link to Instagram
  • Link to Youtube
https://www.adventuresincre.com/wp-content/uploads/2016/02/bw-computer-e1538887017209.jpeg 1080 1620 Spencer Burton https://adventuresincre.com/wp-content/uploads/2022/04/logo-transparent-black-e1649023554691.png Spencer Burton2024-04-28 07:00:282025-07-02 15:38:49Hide and Unhide Tabs using Drop-down Menus in Excel (Updated Apr 2024)
You might also like
DateDif: The “Secret” Excel Formula (Updated 11.14.2020)
A.CRE Geocoding Excel Add-in to Auto-Populate Latitude and Longitude in Excel (Updated Jan 2024)
Using OpenAI’s ChatGPT to Research Real Estate Data
Excel 2016 Disable Animations – Excel 2013 (and Presumably in Excel 2016)
How to Create Dynamic, In-Cell Buttons and Toggles in Microsoft Excel
SUMPRODUCT Weighted Average Using SUMPRODUCT to Calculate Weighted Average in Real Estate (Updated Aug 2024)
Accelerator - Learn More

Featured Content

  • RE Financial Modeling Training
  • Library of Excel Models
  • Post a Job – It’s Free
  • Master Financial Modeling
  • Technical Interview Guide
  • Definitive Guide to Excel
A.CRE Library of Excel Models

Recent Posts

  • The 2008 Financial Crisis, From the Ground Up: Why We Believed Houses Were Safe
  • Real Estate Equity Waterfall Model – IRR and Equity Multiple Hurdles (Updated June 2026)
  • A.CRE Self Storage Development Model (Updated June 2026)
  • Episode 12 of Multipliers: Ask Why Until the Answer Changes
  • A.CRE Jobs of the Week (Updated 6.22.2026)

Note About Models

Models downloaded from A.CRE may contain errors. Verify formulas/methodology before basing investment decisions on any model here. Read our Terms and Conditions of Use and Disclaimer.

★★★★★

Accelerator Reviews

Search Adventures in CRE

Search Search

Have a Question or Need Help?

Visit our Help Section

Contact Adventures in CRE

  • Visit A.CRE Help
  • Via Email
  • Via LinkedIn

You Might Also Like

  • Real Estate Modeling Courses
  • Real Estate Financial Modeling
  • A.CRE Job Board
  • Careers in Commercial Real Estate
  • Real Estate Education

A.CRE Library of Excel Models

  • Browse Excel Models
  • Login/Register
  • View My Downloads
  • Edit Account Details

Terms, Policies, and Disclaimer

  • Privacy Policy
  • Cookie Policy
  • AI Usage Policy
  • Terms of Use
  • Disclaimer
© 2014 - Present - Copyright - www.AdventuresinCRE.com, LLC | Adventures in CRE | A.CRE
  • Link to Facebook
  • Link to Youtube
  • Link to LinkedIn
  • Link to X
  • Link to Tiktok
  • Link to Instagram
Link to: Watch Me Build – American-Style Real Estate Equity Waterfall (Updated Apr 2024) Link to: Watch Me Build – American-Style Real Estate Equity Waterfall (Updated Apr 2024) Watch Me Build – American-Style Real Estate Equity Waterfall (Updated... Link to: Real Estate Capital Account Tracking Tool (Updated Apr 2024) Link to: Real Estate Capital Account Tracking Tool (Updated Apr 2024) Real Estate Capital Account Tracking Tool (Updated Apr 2024)
Scroll to top Scroll to top Scroll to top