Visual Basic Examples

ChilkatHOMEASPVisual BasicVB.NETC#Visual C++CMFCDelphiFoxProJavaPerlPHPPythonRubySQL ServerVBScript

VB Examples

Bounced Mail
Bz2
Character Encoding
CSV
Digital Certificates
Digital Signatures
Email
FTP
HTML-to-XML
HTTP
IMAP
Encryption
MHT / HTML Email
POP3
RSA
S/MIME
SFTP
SMTP
Socket
Spider
SSH
SSH Key
SSH Tunnel
String
Tar
Unicode
Upload
XML
XMP
Zip Compression

More Examples...
Email Object
DKIM / DomainKey
NTLM
DH Key Exchange
DSA
FileAccess
RSS
Atom
Self-Extractor
Service
Bzip2
PPMD
Deflate
LZW


VB Strings
VB Byte Array

 

 

 

 

 

 

 

Extract Files from MIME

Extract files from a MIME message.

Download Chilkat MIME ActiveX

Dim mime As New ChilkatMime

Dim success As Long
success = mime.UnlockComponent("Anything for 30-day trial.")
If (success = 0) Then
    MsgBox "Failed to unlock component"
    Exit Sub
End If

'  Load a MIME document from a file:
'  (.mht and .eml files contain MIME).
success = mime.LoadMimeFile("mst.mht")
If (success = 0) Then
    MsgBox mime.LastErrorText
    Exit Sub
End If

Dim sa As CkStringArray

Set sa = mime.ExtractPartsToFiles("c:/temp/mimeParts")
If (sa Is Nothing ) Then
    Text1.Text = Text1.Text & mime.LastErrorText & vbCrLf
    Exit Sub
End If

Dim i As Long
Dim n As Long
n = sa.Count

'  Display the filepaths of the files created:
For i = 0 To n - 1
    Text1.Text = Text1.Text & sa.GetString(i) & vbCrLf
Next

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