Convert Quarter to Month
I’ve been having to do this a lot lately, and so rather than creating a case statement every time I set out to create an equation to handle the conversion. Since I never got past Intermediate Algebra, it took a lot longer than it probably should have, but I’m still fairly impressed with myself:
m = q + (q * 2) - 2
… and the chalkboard, or trinomial version (thanks Greg):
m = q + 2q - 2
… and finally, the VB function:
Function QuarterMonth(ByVal q As Integer) As Integer
Dim m As Integer
m = q + (q * 2) -2
Return m
End Function
