Thread: Add
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Jacob Skaria Jacob Skaria is offline
external usenet poster
 
Posts: 8,520
Default Add

Please adjust the range...and set your evaluation code. If you are new to VBE
launch VBE using Alt+F11. Insert Module. and paste the below code....Use Step
Into (function key F8) and see what happens...

Sub LoopthroughRange()
Set rngTemp = Sheets("Sheet1").Range("A1:A10")
For Each rngCell In rngTemp
If rngCell.Text = "<condition" Then
'your code to evaluate
End If
Next
End Sub

--
If this post helps click Yes
---------------
Jacob Skaria


"LuisE" wrote:

I need to loop thru a range of cells and evaluate