Public Function Decrypt(ByVal clave As String) As String
' Defino variables
Dim indice As Integer = 1
Dim largo As Integer = 0
Dim final As String = ""

' Calculo el largo de la cadena
largo = Len(Trim(clave))

' Creo un array para contener los dígitos de cada clave
Dim caracteres(largo) As String

' Desencripto los dígitos
For indice = 1 To largo
caracteres(indice) = Mid(clave, indice, 1)
caracteres(indice) = Chr(Asc(caracteres(indice)) - indice)
final = final & caracteres(indice)
Next indice

' Retorno la cadena desencriptada
Return final
End Function