View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Lawlera Lawlera is offline
external usenet poster
 
Posts: 37
Default .select efficiency

Thanks Frank, you put me on the right lines
Sub errorchk(
Dim s1, s2 As Strin
Dim r As Varian
Application.ScreenUpdating = Fals
s1 = "sheet1
s2 = "sheet2
For r = 1 To 10
For c = 1 To 2
'Cells(r, c).Selec
If Sheets(s1).Cells(r, c).Value < Sheets(s2).Cells(r, c).Value Then MsgBox "error at " & Cells(r, c).Addres
Next
Next
MsgBox "Check complete
Application.ScreenUpdating = Tru
Range("a1").Selec
End Sub