Need VBA code to periodically zero out 10,000 cells

  • Thread starter Thread starter lothario
  • Start date Start date
L

lothario

Hi,

I have 10,000 cells that need to be zero-ed out periodically.

Can you give me some VBA code that I can attach to a "Zero Out"
button?

So every time the "Zero Out" button is pressed the cells in the range
a1:a10000 are will be assigned the value of zero.

Thanks,
Luther
 
Sub ZeroOut()
Range("A1:A10000").Value = 0
End Sub

or if you want to make them blank

Sub ClearOut()
Range("A1:A10000").Clearcontents
End Sub
 
Back
Top