D
Dave F
I have the following macro which isn't working:
Sub EachTest()
Dim A As Variant, MyString As String
MyString = "10"
For Each A In Range("A10:A20")
If A.Value = True Then MyString
Next
End Sub
When this is run I get an error: "Compile error. Expected Sub,
Function or Property."
I'm trying to replace TRUE values in A10:A20 with the number 10 and
ignore the FALSE values.
Presumably I'm missing something simple here.
Thanks,
Dave
Sub EachTest()
Dim A As Variant, MyString As String
MyString = "10"
For Each A In Range("A10:A20")
If A.Value = True Then MyString
Next
End Sub
When this is run I get an error: "Compile error. Expected Sub,
Function or Property."
I'm trying to replace TRUE values in A10:A20 with the number 10 and
ignore the FALSE values.
Presumably I'm missing something simple here.
Thanks,
Dave