I'm using this encrypting function psoted by a member:

Public Function SimpleCrypt(ByVal Text As String)

        Dim strTempChar As String = ""
        Dim i As Integer
        For i = 1 To Text.Length
            If Asc(Mid$(Text, i, 1)) < 128 Then
                strTempChar = _
          CType(Asc(Mid$(Text, i, 1)) + 128, String)
            ElseIf Asc(Mid$(Text, i, 1)) > 128 Then
                strTempChar = _
          CType(Asc(Mid$(Text, i, 1)) - 128, String)
            End If
            Mid$(Text, i, 1) = _
                Chr(CType(strTempChar, Integer))
        Next i
        Return Text
    End Function

My problem is when i try to encrypt a string containing the number '5'.
On my database(oracle 11g r2 XE) the number 5 is encrypted as the letter M, but on VB it shows as ยต. So when I compare the contents of the my password textbox to the one in my database, they won't match.

This encryption is at very basic level, best advice don't use it u can find more encryption Try this . Actually this is in c# but you can easily converted to vb.net by online code converter.
Hope this will help you

can u please explain me the entire code?

since m new to vb.net ...can u please explain me the entire code ?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.