Function cadinvertida(cadena As String) As String
Dim invertida() As String
Dim i As Integer
Dim j As Integer
n = Len(cadena)
ReDim invertida(n)
For i = 1 To n
invertida(i - 1) = Mid(cadena, i, 1)
Next i
For j = (n - 1) To 0 Step -1
cadinvertida = cadinvertida & invertida(j)
End Function