This code goes in a standard module (ALt+F11) then right click in the VBA project window top left hand side and choose Insert, Module then paste the code below:
now all you need to do is hilight the range that contains the blanks and data and run the code all empty cells will now have a 0.![]()
Sub Fill_Blanks() Dim MyCell As Range For Each MyCell In Range(Selection.Address) If MyCell = vbNullString Then MyCell.Value = 0 End If Next End Sub
Bookmarks