You might want to hide multiple columns in Microsoft Excel to conceal personal or perplexing data. We can easily hide multiple columns in Excel by using the keyboard shortcuts, Mouse Right-Click, Format command, and VBA Macros. In this article, we’ll learn five quick and suitable ways to hide multiple columns in Excel effectively with appropriate illustrations.
Let’s say, we have a dataset that contains information about 12 different students of ABC School. The Name of the students and ID of those students and their marks in Physics, Chemistry, and Mathematics are given in Columns B, C, D, E, and F respectively. We might hide columns in Excel using the keyboard shortcuts, Mouse Right-Click, Format command, and VBA Macros. Here’s an overview of the dataset for today’s task.
1. Using Keyboard Shortcuts to Hide Multiple Columns in Excel
If you want to hide multiple columns without right-click in Excel, the keyboard shortcut is the easiest way. From our dataset, we will hide marks in Physics, and Chemistry that have been given in columns D, and E respectively. Let’s follow the instructions below to hide multiple columns!
Steps:
- First, select columns D, and E that contain marks in Physics, and Chemistry.
- Hence, press Ctrl + 0 simultaneously on your keyboard.
- As a result, you will be able to hide columns DÂ and E which have been given in the below screenshot.
Read More: How to Hide Columns with Button in Excel
2. Use of Mouse to Hide Multiple Columns
Another easy way is to hide multiple columns in Excel by using the mouse Right-Click. Now, we will hide the columns containing the Physics and Mathematics information. Please follow the steps below to learn!
Steps:
- First, select columns D, and F.
- After that, place your cursor upon any selected columns, and press right-click on your mouse.
- Then, a window will appear in front of you.
- From that window select the Hide option.
- As a result, you can hide selected columns that have been given in the below screenshot.
Read More: Hide Columns with No Data in Excel
3. Hiding Multiple Columns with Format Command in Excel
To hide multiple columns, we will apply the Format command. This is the easiest and most time-saving way in Excel. Now, we will hide the columns that contain the information on Physics and Chemistry. Please follow the steps below to learn!
Steps:
- First, select columns D, and E.
- Hence, from your Home ribbon, go to,
Home → Cells → Format → Hide & Unhide → Hide Columns
- After clicking on the Hide Columns option, you will be able to hide multiple columns DÂ and E.
Read More: How to Hide and Unhide Columns in Excel
4. Applying Group Feature to Hide Multiple Columns
In this method, we’ll learn how to hide multiple columns in Excel by using the Group feature. From our dataset, we will hide the columns that contain the information on Identification Number, Physics, and Chemistry. Please follow the instructions below to learn!
Step 1:
- First, select columns C to E.
- After that, from your Data ribbon, go to,
Data → Outline → Group → Group
Step 2:
- Hence, a Group dialog box will appear in front of you.
- From the Group window, firstly select Columns.
- At last, press OK.
- Further, the Minus(-) sign will appear on the topmost side of the columns.
- After that, press on the Minus(-) sign like the below screenshot to hide columns.
- Finally, you will get your desired output that has been given below screenshot.
5. Running Excel VBA Code to Hide Multiple Columns
Last but not least, I’ll show how to hide multiple columns in Excel by using a simple VBA code. It’s very helpful for some particular moments and a time-saving way also. From our dataset, we will hide multiple columns. Let’s follow the instructions below to hide multiple columns!
Step 1:
- First of all, select cells C4 to E16.
- Hence, open a Module.
- To do that, firstly, from your Developer tab, go to,
Developer → Visual Basic
- After clicking on the Visual Basic ribbon, a window named Microsoft Visual Basic for Applications – Hide Multiple Columns will instantly appear in front of you.
- From that window, we will insert a module for applying our VBA code.
- To do that, go to,
Insert → Module
Step 2:
- Then, type the VBA code in the created Module.
Sub Hide_Multiple_Columns_VBA()
Columns("C:E").Hidden = True
End Sub
- Further, we run the code, to do that, go to,
Run → Run Sub/UserForm
Step 3:
- Thereafter, run the code and the output will be like the following.
Things to Remember
↪ If the Developer Menu does not appear in the Menu Bar, press ALT + F11 keys on your keyboard to open the Microsoft Visual Basic for Applications window.
Download Practice Workbook
Download this practice workbook to exercise while you are reading this article.
Conclusion
I hope all of the suitable methods mentioned above to hide multiple columns will now provoke you to apply them in your Excel spreadsheets with more productivity. You are most welcome to feel free to comment if you have any questions or queries.