View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Max Max is offline
external usenet poster
 
Posts: 9,221
Default Sub to clear cells with zeros or null strings within a selecte

Runs great, Jay. Many thanks.

I changed: itm.Clear
to itm.ClearContents
to suit my purpose
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Jay" wrote:
Sub MaxSingapore()
Set rng = Selection
For Each ar In Selection.Areas
For Each itm In ar
If Trim(itm.Value) = "" Or itm.Value = 0 Then itm.Clear
Next 'itm
Next 'ar
End Sub
--
Jay