ive been stuck for 2 days
Thanks Tom, I'll save this one.
--
Gary's Student
gsnu200703
"Tom Ogilvy" wrote:
Sub demo()
Dim r As Range
Set r = Range("A2:A5002")
For Each rr In r
If len(trim(rr.Value)) = 0 Then
rr.Offset(0, 14).Clear
End If
Next
End Sub
--
Regards,
Tom Ogilvy
" wrote:
ahhh well no the cells arent really empty they just appear empty.
sorry there are formulas in every cell
On Jan 29, 1:33 pm, wrote:
so what am i doing wrong, i used colum (O) as an example its really
colum (M) but i changed the 14 to a 12 in
(( rr.Offset(0, 12).Clear))
here is whats in the vbs editor
------------------------------------------------------------------
Private Sub Workbook_Open()
ActiveSheet.Unprotect Password:="1111"
Columns("A:N").Select
Selection.Sort Key1:=Range("K1"), Order1:=xlAscending, Header:=yes,
OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom
Dim r As Range
Set r = Range("A2:A5002")
For Each rr In r
If IsEmpty(rr.Value) Then
rr.Offset(0, 12).Clear
End If
Next
ActiveSheet.Protect DrawingObjects:=True, Contents:=True,
Scenarios:=True, Password:="onlyone1"
ActiveWorkbook.Save
End Sub
_________________________________________________
i actually tried all 4 cant figure out what im doing wrong
|