I have this Excel formula which I would like to implement via VBA, unfortunately it keeps yielding an error.
My Excel formula:
IF(isemptyornothing(A1:A50); ""; IF(ISNUMBER(VALUE(A1:A50)); VALUE(A1:A50); A1:A50))
My VBA attempt:
Range("B1:B50").Formula = _
"=IF(IsEmptyorNothing(A1:A50), "", IF(ISNUMBER(VALUE(A1:A50)), VALUE(A1:A50), A1:A50))"
This yields the following error:
"Run-time error '1004': Application-defined or object-defined error"
Being a novice in VBA, I am not sure what to do with this.