Answers for "vba sheet for each"

VBA
0

excel vba for each

Dim Found, MyObject, MyCollection 
Found = False    ' Initialize variable. 
For Each MyObject In MyCollection    ' Iterate through each element.  
    If MyObject.Text = "Hello" Then    ' If Text equals "Hello". 
        Found = True    ' Set Found to True. 
        Exit For    ' Exit loop. 
    End If 
Next
Posted by: Guest on January-22-2021

Code answers related to "VBA"

Browse Popular Code Answers by Language