I've created this function:
Public Function getLastCellValue(ByVal row As Integer, ByVal column As String) As String
If (Cells(row, column).Value = "") Then
getLastCellValue = getLastCellValue(row - 1, column)
Else: getLastCellValue = Cells.Item(row, column).Value
End If
End Function
When I use it in a cell this:
=getLastCellValue(1,"C")
Excel tells me that the function contains an error and focuses on the second parameter: "C".
I'm going crazy because I do not understand the mistake.
,) to separate functions parameters; if your name tells me something about your nationality, I guess you're using an Italian/Spanish system (which means you should separate inputs by semi-column (;)