In this video, I will show you 3 different methods you can use to quickly delete blank columns in Excel.
I am also going to cover one additional method that works well but needs to be used cautiously, as it can lead to issues
00:00 Intro
00:25 Delete Blank Columns using SORT method
03:12 Delete Blank Columns using Find & Replace method
05:55 Delete Blank Columns using VBA
10:07 Delete Blank Columns using Go To Special (NOT recommended)
------------------------------------------------------------------------------------------------
Below is the VBA code I used in the video:
'Code Developed by Sumit Bansal from TrumpExcel.com
Sub DeleteBlankColumns()
Dim EntireColumn As Range
On Error Resume Next
Application.ScreenUpdating = True
For i = Selection.Columns.Count To 1 Step -1
Set EntireColumn = Selection.Cells(1, i).EntireColumn
If Application.WorksheetFunction.CountA(EntireColumn) = 0 Then
EntireColumn.Delete
End If
Next
Application.ScreenUpdating = True
End Sub
------------------------------------------------------------------------------------------------
Video about Personal Macro Workbook - • Personal Macro Workboo...
☕ If you find my Excel videos useful and would like to support me, you can buy me a coffee - www.buymeacoffee.com/SumitB
✅ Free Excel Course (Basic to Advanced) - trumpexcel.com/learn-excel/
✅ Free Dashboard Course - bit.ly/free-excel-dashboard-c...
✅ Free VBA course - bit.ly/excel-vba-course
✅ Free Power Query Course - bit.ly/power-query-course
✅ Best Excel Books: trumpexcel.com/best-excel-books/
Subscribe to get awesome Excel Tips every week: kzitem.info...
#Excel #ExcelTips #ExcelTutorial
Негізгі бет 3 Right Ways to Delete Blank Columns in Excel
Пікірлер: 37