Jun 27 2021 08:09 PM
Jun 28 2021 01:58 PM
The UDFs didn't work because the arguments on the worksheet do not match the parameters declared in the code. Why do you want to use VBA anyway. I have included modified VBA and worksheet formulas. To my mind, worksheet formulas are better, especially if you can use LET or even LAMBDA.