Sample code for 30+ languages & platforms
Visual Basic 6.0 Requires Chilkat v11.0.0+

Transition from Imap.FetchBundleAsMime to Imap.FetchSingleBd

Provides instructions for replacing deprecated FetchBundleAsMime method calls with FetchSingleBd. The code below uses the replacement API without constructing the deprecated returned array.

Chilkat Visual Basic 6.0 Downloads

Visual Basic 6.0
Dim success As Long
success = 0

Dim imap As New ChilkatImap

'  ...
'  ...

Dim mset As New MessageSet
success = imap.QueryMbx("FROM joe@example.com",1,mset)
'  ...
'  ...

'  Replace the deprecated FetchBundleAsMime method using FetchSingleBd.

imap.AutoDownloadAttachments = 1

Dim bdMime As New ChilkatBinData
Dim bUid As Long
bUid = mset.HasUids
Dim numEmails As Long
numEmails = mset.Count
Dim i As Long
i = 0
Do While i < numEmails
    success = imap.FetchSingleBd(mset.GetId(i),bUid,bdMime)
    '  ...
    '  ...

    i = i + 1
Loop