AlaskanVBA
New Member
- Joined
- Mar 27, 2011
- Messages
- 6
How are we able to get the following excel formular to work properly in VBA?
<TABLE class=collapse id=NestedTable2 name="NestedTable2"><TBODY><TR class=trbgodd><TD>=IF(ISNUMBER(SEARCH("v",A2)),"OK", "Not OK")</TD><TD>Checks to see if A2 contain the letter v (OK)</TD></TR><TR class=trbgeven><TD>=ISNUMBER(SEARCH("BD",A3))</TD><TD>Checks to see if A3 contains BD (TRUE)</TD></TR></TBODY></TABLE>
below code returns an error.
<TABLE class=collapse id=NestedTable2 name="NestedTable2"><TBODY><TR class=trbgodd><TD>=IF(ISNUMBER(SEARCH("v",A2)),"OK", "Not OK")</TD><TD>Checks to see if A2 contain the letter v (OK)</TD></TR><TR class=trbgeven><TD>=ISNUMBER(SEARCH("BD",A3))</TD><TD>Checks to see if A3 contains BD (TRUE)</TD></TR></TBODY></TABLE>
below code returns an error.
Code:
Application.WorksheetFunction.If.Isnumber.Search("v",Cells(1,2)),"OK","Not OK")