0

I want to create a UDF (user defined function) similar to Sumif below.

  =SUMIF(F10:F15,">20")

But how do I use the string parameter ">20" in the if statement. I tried

  If (A Like ConditionalString) Then

But it is working for wildcards and not for the logical operators. I need it work for both wildcards and logical operators as well.

The King
  • 4,600
  • 3
  • 39
  • 58
  • Look [HERE](https://stackoverflow.com/questions/56858571/merge-values-of-column-b-based-on-common-values-on-column-a) where I did a TEXTJOINIFS and you can see how I did it. – Scott Craner Oct 07 '21 at 18:47
  • The basics, is that you need to test whether the opperands are there and if not put `=` in front and use `Application.Evaluate` to test if true or not. And if you want wildcards you will need to test for those and use like instead. But the main thing is that you will need to do the branching and logical path. – Scott Craner Oct 07 '21 at 18:50
  • What specific wildcards and what specific operators? – Tim Williams Oct 07 '21 at 23:14

0 Answers0