Chilkat2-Python
Chilkat2-Python
Transition from MailMan.FetchMultipleMime to MailMan.FetchMimeBd
Provides instructions for replacing deprecated FetchMultipleMime method calls with FetchMimeBd.Chilkat Chilkat2-Python Downloads
import sys
import chilkat2
success = False
mailman = chilkat2.MailMan()
# ...
# ...
saUidls = chilkat2.StringArray()
saUidls.Append("aaa")
saUidls.Append("bbb")
saUidls.Append("ccc")
stUidls = chilkat2.StringTable()
stUidls.Append("aaa")
stUidls.Append("bbb")
stUidls.Append("ccc")
# ------------------------------------------------------------------------
# The FetchMultipleMime method is deprecated:
# saMime is a CkStringArray
saMime = mailman.FetchMultipleMime(saUidls)
if (mailman.LastMethodSuccess == False):
print(mailman.LastErrorText)
sys.exit()
# ...
# ...
# ------------------------------------------------------------------------
# Do the equivalent using FetchMimeBd.
success = False
bdMime = chilkat2.BinData()
numUidls = stUidls.Count
i = 0
while i < numUidls :
success = mailman.FetchMimeBd(stUidls.StringAt(i),bdMime)
# ...
# ...
i = i + 1