Visual FoxPro
Visual FoxPro
Transition from Zip.GetEntryByID to Zip.EntryById
Provides instructions for replacing deprecated GetEntryByID method calls with EntryById.Chilkat Visual FoxPro Downloads
LOCAL lnSuccess
LOCAL loZip
LOCAL lnId
LOCAL loEntryObj
LOCAL loZe
lnSuccess = 0
loZip = CreateObject('Chilkat.Zip')
* ...
* ...
lnId = 123
* ------------------------------------------------------------------------
* The GetEntryByID method is deprecated:
loEntryObj = loZip.GetEntryByID(lnId)
IF (loZip.LastMethodSuccess = 0) THEN
? loZip.LastErrorText
RELEASE loZip
CANCEL
ENDIF
* ...
* ...
RELEASE loEntryObj
* ------------------------------------------------------------------------
* Do the equivalent using EntryById.
* Your application creates a new, empty ZipEntry object which is passed
* in the last argument and filled upon success.
loZe = CreateObject('Chilkat.ZipEntry')
lnSuccess = loZip.EntryById(lnId,loZe)
IF (lnSuccess = 0) THEN
? loZip.LastErrorText
RELEASE loZip
RELEASE loZe
CANCEL
ENDIF
RELEASE loZip
RELEASE loZe