VB.NET Examples

ChilkatHOMEASPVisual BasicVB.NETC#Visual C++CMFCDelphiFoxProJavaPerlPHPPythonRubySQL ServerVBScript



VB.NET Examples

Bounced Mail
Character Encoding
Digital Certificates
Digital Signatures
Email
FTP
HTML to XML
HTTP
IMAP
Encryption
MHT / HTML Email
PFX
RSA Encryption
S/MIME
Socket
Spider
Tar Archive
Upload
XML
XMP
Zip Compression
Misc

More Examples...
Email Object
POP3
SMTP
RSS
Atom
Self-Extractor

Byte Array
VB.NET FTPS
System.IO

Unreleased...
Service
PPMD
Deflate
Bzip2
LZW
Bz2
DH Key Exchange
DSA
Icon

 

 

 

 

 

 

Digest-MD5 Hash a String returning a Hexidecimalized Hash String

Source code to Digest-MD5 hash a string, returning the hash value as a hexidecimal encoded string.

        ' This example uses the Chilkat .NET encryption library, which can be downloaded
        ' at http://www.chilkatsoft.com/downloads.asp

        ' Create an instance of the Chilkat encryption class.
        Dim crypt As New Chilkat.Crypt2()

        ' Any code begins the 30-day trial.
        crypt.UnlockComponent("30-day-trial")

        ' Set the hash algorithm to "MD5", for the Digest-MD5 hash algorithm
        crypt.HashAlgorithm = "MD5"

        ' Tell the encryption object to return a hexidecimalized string.
        crypt.EncodingMode = "hex"
        ' EncodingMode can be set to "URL", "QP", or "Base64" also.

        ' Generate some data to hash...
        Dim str As String
        Dim i As Integer
        For i = 1 To 10
            str = str + "This is VB.NET sample line " & i & vbCrLf
        Next
        TextBox1.Text = str

        ' Create a Digest-MD5 hash, returning the result as a hexidecimal string.
        TextBox2.Text = crypt.HashStringENC(str)




Important: The download for this example does not contain the ChilkatDotNet.dll which
must be downloaded and installed separately at http://www.chilkatsoft.com/downloads.asp.
Once installed, add a reference to the DLL in the project by following the instructions at
http://www.example-code.com/vbdotnet/step2.asp

 

Need a specific example? Send a request to support@chilkatsoft.com

© 2000-2007 Chilkat Software, Inc. All Rights Reserved.

Mail Component · XML Parser