1. Create a UDF (User Defined Function)
To create this Function, execute the following steps
Use the If Then statement in Excel VBA code lines function to act if the both 2 specific condition is met. Insert the below code in a New Module.
This Will Create A new UDF (User Defined Function) with name Lhazs(Lval, Lvxc, Lvzl) we Can use this As we Required. type in Excel the function As = Lhazs(Lval, Lvxc, Lvzl)), the UDF Comes up in small letter’s to differentiate itself from “tandard Excel Formula,if any one condition met it turns TRUE.
This Code lines will create function Lhazs()
In Cell D1 Type
=Lhazs(A1,B1,C1)
2. Use Excel Formulas (XOR)
Syntax
XOR(logical1, [logical2],…)
=XOR(A1>30,B1>50,C1=20)