M
Monk
The following is a part of a macro that works fine in later versions of
excel. However some users are still on Excel 97 and the replace function in
the code is not recognised. Can someone suggest code that may work under
both 97 and later versions or amended code that will wotk specifically for
97. I having being toying with the substitute command with little success.
Dim Rng As Range, ix As Long
Set Rng = Intersect(Range("D765536"), ActiveSheet.UsedRange)
For ix = Rng.Count To 1 Step -1
If Trim(Replace(Rng.Item(ix).Text, Chr(160), Chr(32))) = "" Then
Rng.Item(ix).EntireRow.Delete
End If
Next
Thanks
excel. However some users are still on Excel 97 and the replace function in
the code is not recognised. Can someone suggest code that may work under
both 97 and later versions or amended code that will wotk specifically for
97. I having being toying with the substitute command with little success.
Dim Rng As Range, ix As Long
Set Rng = Intersect(Range("D765536"), ActiveSheet.UsedRange)
For ix = Rng.Count To 1 Step -1
If Trim(Replace(Rng.Item(ix).Text, Chr(160), Chr(32))) = "" Then
Rng.Item(ix).EntireRow.Delete
End If
Next
Thanks