| This did work for me:
ActiveSheet.Range("A7:BW16,CA7:CV16," & _
"A18:DN18,A20:BA20,A25:BW34," & _
"CA25:CV34,A36:DN36,A38:BA38," & _
"A43:BW52,CA43:CV52,A54:DN54," & _
"A56:BA56,A61:BW70,CA61:CV70," & _
"A72:DN72,A74:BA74,A79:BW88," & _
"CA79:CV88,A90:DN90,A92:BA92," & _
|
|
 |
|
 |
Group: microsoft.public.excel.misc · Group Profile · Search for Dn18 in microsoft.public.excel.misc
Author: Dave Peterson
Date: Apr 26, 2007 04:13
Barb's code needs a space before that underscore character. Sub ClearRange() dim myrange as range set myrange = union(range("A7:BW16"),range("CA7:CV16"), range("A18:DN18"), _ range("A20:BA20")) myrange.value = 9 end sub Alternatively, you could use: Option Explicit Sub ClearRange2() Activesheet.Range("A7:BW16,CA7:CV16,A18:DN18,A20:BA20").Value = 9 end Sub M.A.Tyler
|