I am terrible with writing functions using the R1C1 style. I assume this can be written better that I have it.
Help?
Code:
Function Revenue_CQ(x As String)
Dim rw As Integer
If x = "C" Then
rw = 12
ElseIf x = "P" Then
rw = 61
End If
With Sheets("Info")
If Quarter() = "1Q" Then
Revenue_CQ = .Range("C" & rw)
ElseIf Quarter() = "2Q" Then
Revenue_CQ = .Range("I" & rw)
ElseIf Quarter() = "3Q" Then
Revenue_CQ = .Range("O" & rw)
ElseIf Quarter() = "4Q" Then
Revenue_CQ = .Range("U" & rw)
End If
End With
End Function