VBA Does not recognize cell contents
I have a workbook "Optvol" having the word "put" in cell A10. In a macro:
If Workbooks("optvol.xlsx").Sheets("optvol").Range("A 10") = "put" Then
Range("c4") = "it works"
End If
C4 is in the active workbook, different from "Optvol". Nothing happens upon execution, and there is no error message
Clearly, for some reason the contents of Optvol A10 are not recognized.
Any idea what I'm doing wrong? Appreciate all help, thanks.
|