Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Replacing blank cells with zeros
Hello, I have a an area of a spreadsheet 15 columns wide and 256 rows deep.
Some of the cells are populated with numbers but some are blank. I would like to replace blank cells with zeros. What is the most efficient VBA method of achieving that. Thank you |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Replacing blank cells with zeros
You could use code like that below
Sub InsertZeroInBlank() Dim myRng As Range Set myRng = Range("A1:O256") myRng.SpecialCells(xlCellTypeBlanks).Value = 0 End Sub -- HTH Nick Hodge Microsoft MVP - Excel Southampton, England HIS "Ben" wrote in message ... Hello, I have a an area of a spreadsheet 15 columns wide and 256 rows deep. Some of the cells are populated with numbers but some are blank. I would like to replace blank cells with zeros. What is the most efficient VBA method of achieving that. Thank you |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Averaging blank or cells with Zeros in them. | Excel Worksheet Functions | |||
Replacing blank cells with zeros | Excel Discussion (Misc queries) | |||
prevent copied blank cells from replacing existing data | Excel Worksheet Functions | |||
Replacing blank cells | Excel Worksheet Functions | |||
I want blank cells, but they're all zeros now that I have formatted them | Excel Discussion (Misc queries) |