P
PJohnson
I would appreciate any help here. Why am I not getting any returns? The
function calls without error, but I get no returns. I do this type of things
with numbers all the time, but never with text. Where am I going wrong?
If active cell is A1 with the fuction call (e.g.,
"=personal.xls!PetesMacro(B1)") and B1 has somthing like "Agriculture":
Thanks in advance.
Pete
=========
Function PetesMacro(MyText) As String
MyText = Trim(MyText)
MyText = Left(MyText, 1)
MyText = UCase(MyText)
Select Case MyText
Case "A"
MyText = "has successfully completed an"
Case "E"
MyText = "has successfully completed an"
Case "I"
MyText = "has successfully completed an"
Case "O"
MyText = "has successfully completed an"
Case "U"
MyText = "has successfully completed an"
Case Else
MyText = "has successfully completed a"
End Select
End Function
function calls without error, but I get no returns. I do this type of things
with numbers all the time, but never with text. Where am I going wrong?
If active cell is A1 with the fuction call (e.g.,
"=personal.xls!PetesMacro(B1)") and B1 has somthing like "Agriculture":
Thanks in advance.
Pete
=========
Function PetesMacro(MyText) As String
MyText = Trim(MyText)
MyText = Left(MyText, 1)
MyText = UCase(MyText)
Select Case MyText
Case "A"
MyText = "has successfully completed an"
Case "E"
MyText = "has successfully completed an"
Case "I"
MyText = "has successfully completed an"
Case "O"
MyText = "has successfully completed an"
Case "U"
MyText = "has successfully completed an"
Case Else
MyText = "has successfully completed a"
End Select
End Function