![]() |
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
(AutoIt) Transition from ZipEntry.NextEntry to ZipEntry.GetNextProvides instructions for replacing deprecated NextEntry method calls with GetNext. Note: This example requires Chilkat v11.0.0 or greater.
; ------------------------------------------------------------------------ ; The NextEntry method is deprecated. ; See below or code showing how to rewrite using EntryAt/GetNext $oZip = ObjCreate("Chilkat.Zip") Local $bSuccess = $oZip.OpenZip("qa_data/zips/xml_files.zip") If ($bSuccess <> True) Then ConsoleWrite($oZip.LastErrorText & @CRLF) Exit EndIf Local $oEntry = $oZip.FirstEntry() If ($oZip.LastMethodSuccess = False) Then ConsoleWrite("This zip archive is empty." & @CRLF) Exit EndIf Local $bFinished = False While $bFinished = False If ($oEntry.IsDirectory = False) Then ConsoleWrite($oEntry.FileName & @CRLF) Else ConsoleWrite("(directory) " & $oEntry.FileName & @CRLF) EndIf Local $oNext = $oEntry.NextEntry() If ($oEntry.LastMethodSuccess = False) Then $bFinished = True EndIf $oEntry = $oNext Wend $oZip.CloseZip ConsoleWrite("----" & @CRLF) ; ------------------------------------------------------------------------ ; Do the equivalent using EntryAt/GetNext. $bSuccess = $oZip.OpenZip("qa_data/zips/xml_files.zip") $oZe = ObjCreate("Chilkat.ZipEntry") $oZip.EntryAt(0,$oZe) Local $bEntryValid = True While $bEntryValid = True If ($oZe.IsDirectory = False) Then ConsoleWrite($oZe.FileName & @CRLF) Else ConsoleWrite("(directory) " & $oZe.FileName & @CRLF) EndIf $bEntryValid = $oZe.GetNext() Wend $oZip.CloseZip |
© 2000-2025 Chilkat Software, Inc. All Rights Reserved.