![]() |
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
(PureBasic) Transition from Imap.FetchSequenceAsMime to Imap.FetchSingleBdProvides instructions for replacing deprecated FetchSequenceAsMime method calls with FetchSingleBd. Note: This example requires Chilkat v11.0.0 or greater.
IncludeFile "CkBinData.pb" IncludeFile "CkImap.pb" IncludeFile "CkStringArray.pb" Procedure ChilkatExample() imap.i = CkImap::ckCreate() If imap.i = 0 Debug "Failed to create object." ProcedureReturn EndIf ; ... ; ... startSeqNum.i = 1 count.i = 5 ; ------------------------------------------------------------------------ ; The FetchSequenceAsMime method is deprecated: sa.i = CkImap::ckFetchSequenceAsMime(imap,startSeqNum,count) If CkImap::ckLastMethodSuccess(imap) = 0 Debug CkImap::ckLastErrorText(imap) CkImap::ckDispose(imap) ProcedureReturn EndIf ; ... ; ... CkStringArray::ckDispose(sa) ; ------------------------------------------------------------------------ ; Do the equivalent using FetchSingleBd. CkImap::setCkAutoDownloadAttachments(imap, 1) success.i = 0 bdMime.i = CkBinData::ckCreate() If bdMime.i = 0 Debug "Failed to create object." ProcedureReturn EndIf bUid.i = 0 i.i = 0 While i < count success = CkImap::ckFetchSingleBd(imap,startSeqNum + i,bUid,bdMime) ; ... ; ... i = i + 1 Wend CkImap::ckDispose(imap) CkBinData::ckDispose(bdMime) ProcedureReturn EndProcedure |
© 2000-2025 Chilkat Software, Inc. All Rights Reserved.