VBScript Examples

ChilkatHOMEAndroid™ASPVisual BasicVB.NETC#iOS (IPhone)Objective-CC++CMFCDelphiFoxProJavaPerl
PHP ExtensionPHP ActiveXPythonPowerShellRubySQL ServerVBScript

VBScript Examples

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

More Examples...
Amazon S3
Email Object
DKIM / DomainKey
NTLM
FileAccess
Byte Array
RSS
Atom
Service
PPMD
Deflate
DH Key Exchange
DSA
Bzip2
LZW

 

 

 

 

 

 

 

Unpack HTML Email to Files

Unpacks an HTML email into an HTML file and related files (images and style sheets). The links within the HTML are updated to point to the files unpacked and saved to disk.

Download Chilkat Email ActiveX

Download 32-bit Chilkat IMAP ActiveX (.msi)

Download All 32-bit Chilkat ActiveX Components (.zip)

Download All 64-bit Chilkat ActiveX Components (.zip)

set email = CreateObject("Chilkat.Email2")

success = email.LoadEml("bonaire.eml")
If (success <> 1) Then
    MsgBox email.LastErrorText
    WScript.Quit
End If

'  Is this an HTML email?
If (email.HasHtmlBody() = 1) Then

    '  Unpack the HTML to files.  The image and css URLs
    '  in the HTML are modified to point to the files extracted to disk.
    unpackDir = "c:/temp"
    partsSubdir = "images"
    htmlFilename = "thisEmail.html"
    success = email.UnpackHtml(unpackDir,htmlFilename,partsSubdir)
    If (success <> 1) Then
        MsgBox email.LastErrorText
    End If

    '  If the UnpackHtml method was successful, the
    '  HTML is written to c:/temp/thisEmail.html and
    '  the image files are located in c:/temp/images

End If


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

Mail Component · XML Parser