The code looks exactly what SUMIF() does, except I can't get the syntax for using ISNUMBER() as a SUMIF() citerion.

I preferred a formula in this, as in other cases, because being able to understand where the cell's display is coming from is important to me in using data properly and avoiding mistakes. That approach is invalidated, of course, if the formula is too arcane to interpret easily - my definition of inelegant. Using named ranges helps - I've some long SUMPRODUCT() formulas which almost read like an English (or American) sentence.

I do use code extensively, for procedures, and UDFs where their function is as obvious as, say, SUM() when seen in a formula - eg a UDF for SUBTOTALIF() or my favourite: CELLABOVE which avoids endless issues with totals when ranges are extended.

Here is a breakdown of how the UDF compares with the cell formula =Sumif(Range, criteria, sum range)

Public Function SumNum(rng As Range) : receives to function call and sets the range variable, rng, to the value of the range in the cell formula

Application.Volatile : Any change to work sheet re-runs the macro to update the cell

For Each cell In rng : Looks at each cell in the range passed to the function from the cell formula. The For Each cell in rng takes the place of the range

If WorksheetFunction.IsNumber(cell) Then num = num + cell : If the value in the cell is a number then add it to the running total.
:The IF WorksheetFunction.IsNumber(cell) statement takes the place of the criteria
:the num=num + cell adds the sum range

Next cell : Loops back toFor each statement until cycle through all cells in range

SumNum = num : Sets SumNum with the running total then outputs as the returned cell value.

That was what I tried to do with SUMIF when I posted my alternative "elegant" solution. Couldn't get SUMIF to work with a criterion using ISNUMBER(). Something like
=SUMIF(range,ISNUMBER(range),range)
or
=SUMPRODUCT(range,ISNUMBER(range))
or
=SUM(range*ISNUMBER(range))