![]() |
Chilkat HOME Android™ AutoIt C C# C++ Chilkat2-Python CkPython Classic ASP DataFlex Delphi DLL Go Java Node.js Objective-C PHP Extension Perl PowerBuilder PowerShell PureBasic Ruby SQL Server Swift Tcl Unicode C Unicode C++ VB.NET VBScript Visual Basic 6.0 Visual FoxPro Xojo Plugin
(Visual Basic 6.0) Save HTML Email Embedded ImagesSaves HTML embedded items to files in a subdirectory. Images, style sheets, and anything else embedded within HTML, are not considered to be attachments. Instead, these items are "related item". The Chilkat email object provides a set of methods/properties for accessing the related items within an email.
Dim email As New ChilkatEmail ' Load an email object containing HTML with embedded images. Dim success As Long success = email.LoadEml("myEmails/HtmlEmail.eml") If (success <> 1) Then Debug.Print email.LastErrorText Exit Sub End If ' Iterate over the related items. ' Print the file name and save each to a file. Dim i As Long i = 0 Dim numRelated As Long numRelated = email.NumRelatedItems Do While i < numRelated Debug.Print email.GetRelatedFilename(i) success = email.SaveRelatedItem(i,"myRelatedItemsDir") If (success <> 1) Then Debug.Print email.LastErrorText Exit Sub End If i = i + 1 Loop |
© 2000-2025 Chilkat Software, Inc. All Rights Reserved.