FeeKey + UnFeeKey

Protect Numbers by encoding them into Alphabetic
And convert them back
Converts 12345 to ABCDE and the other way.
Simple way to encryption I did back in 1995
FeeKey security (Convert 1234567890 to ABCDEFGHIJ)
where 1 = A, 2 = B, 3= C, etc..., and convert it vice versa

CodeFunctionName
What is this?

Public

Tested

Original Work
Function FeeKey(Numeral)
    Dim T1, T2, T3, NewFee
    T3 = CStr(Numeral)
    NewFee = ""
    For i = 1 To Len(T3)
        T2 = Mid(T3, i, 1)
        If T2 = "0" Then T2 = "10"
        If T2 = "." Then GoTo Next1
        If Val(T2) = 0 Then GoTo NextI
        NewFee = NewFee & Chr(val(T2) + 64)
        GoTo NextI
Next1:
        NewFee = NewFee & T2
        GoTo NextI
NextI:
    Next i
    FeeKey = NewFee
End Function
Function UnFeeKey(FeeKey)
    ' FeeKey security (Convert 1234567890 to ABCDEFGHIJ)
    ' where 1 = A, 2 = B, 3 = C, etc..., and convert it vice versa)
    Dim NewFee, T1, T2
    NewFee = ""
    For i = 1 To Len(FeeKey)
        T2 = Mid(FeeKey, i, 1)
        T1 = Asc(UCase(T2))
        If T2 = "." Then GoTo Next1
        If T1 < 65 Or T1 > 74 Then GoTo NextI
        If T1 = 74 Then T1 = 64
        NewFee = NewFee & T1 - 64
        GoTo NextI
Next1:
        NewFee = NewFee & T2
        GoTo NextI
NextI:
    Next i
    UnFeeKey = CDbl(NewFee)
End Function

Numeral
or
FeeKey

Views 926

Downloads 307

CodeID
DB ID

ANmarAmdeen
602
Attachments
Revisions

v1.0

Wednesday
November
11
2020