I have been at this for over an hour now and can't seem to find an answer or figure it out.
I have this IfError VBA code I've been using that will return a 0 for me.
Sub WrapFormulasWIthIFERROR_0()
Dim Cell As Range
For Each Cell In Selection
If Cell.HasFormula Then
If Left(Cell.Formula, 9) <> "=IFERROR(" Then
Cell.Formula = "=IFERROR(" & Mid(Cell.Formula, 2) & ",""0"")"
End If
End If
Next
End Sub
However, the "0" it returns is in text format and not number format. I need it to be in number format as there are some additional formulas I'm using that require it to be a number. Does anyone know the quick fix for this? Sorry, I'm still learning here and I'm sure this is something super easy.
I have this IfError VBA code I've been using that will return a 0 for me.
Sub WrapFormulasWIthIFERROR_0()
Dim Cell As Range
For Each Cell In Selection
If Cell.HasFormula Then
If Left(Cell.Formula, 9) <> "=IFERROR(" Then
Cell.Formula = "=IFERROR(" & Mid(Cell.Formula, 2) & ",""0"")"
End If
End If
Next
End Sub
However, the "0" it returns is in text format and not number format. I need it to be in number format as there are some additional formulas I'm using that require it to be a number. Does anyone know the quick fix for this? Sorry, I'm still learning here and I'm sure this is something super easy.