VBA macro help

J

jessica247

Excel Chiefs,
I'm a new entrant to the world of VBA.I have a large excel workboo
litered with tons of macros. However I need a macro that will logicall
test these entries and return a value "ENTRY Valid", "warning check f
file", etc in cell F24 how will i do this? Also if i want the value a
a msg box pop up instead of in cell F24 what additional code will
require?Below is the Logical test :


IF(AND(I13=I15, (ABS((K15-K13)/K15)< 0.05),$M$13=$M$15),"ENTR
Valid",IF(OR(M13/O13>1.9),"","WARNING check FI file !"))

Any help will be sincerly appreciated.
Je
 
J

jessica247

Thanks. However this didn't help. What I'm actually looking for is not
validation tool as my first mail might have suggested, rather a logi
test in VBA that can be run by clicking a botton named "run1" and base
on the conditions met in the IF's display an answer.
Thanks & regards
Jes
 
D

Don Guillett

IF(AND(I13=I15, (ABS((K15-K13)/K15)< 0.05),$M$13=$M$15),"ENTRY
Valid",IF(OR(M13/O13>1.9),"","WARNING check FI file !"))

something like this
sub warnings
if range("i13")=range("i15") and
abs((range("k15")-range("k13"))/range("k15")<.05 then
range("m13")=rang("m15")
else
you get the idea
end if
end sub
 
Top