Visual Basic Examples

ChilkatHOMEASPVisual BasicVB.NETC#Visual C++CMFCDelphiFoxProJavaPerlPHPPythonRubySQL ServerVBScript

VB Examples

Bounced Mail
Character Encoding
Digital Certificates
Digital Signatures
Email
FTP
HTML-to-XML
HTTP
IMAP
Encryption
MHT / HTML Email
RSA Encryption
S/MIME
Socket
Spider
String
Tar
Unicode
Upload
XML
XMP
Zip Compression

More Examples...
Email Object
POP3
SMTP
RSS
Atom
Self-Extractor


VB Strings
VB Byte Array

Unreleased...
Service
PPMD
Deflate
Bzip2
LZW
Bz2
DH Key Exchange
DSA
Icon

 

 

 

 

 

 

 

Find File in Zip by Filename

Download Chilkat Zip ActiveX

Visual Basic 6.0 example to find a file within a Zip archive by filename.

    ' Demonstrates how to find a file in a Zip when the filename
    ' is known, but not the path.
    Dim zip As New ChilkatZip2
    zip.UnlockComponent "Anything for 30-day trial"
    
    success = zip.OpenZip("test.zip")
    If (success = 0) Then
        MsgBox zip.LastErrorText
        Exit Sub
    End If
    
    ' We want to find the file "dudeC.gif"
    Dim zipEntry As ChilkatZipEntry2
    
    ' First, see if the exact match exists, without any directory path.
    Set zipEntry = zip.FirstMatchingEntry("dudeC.gif")
    ' Now look for any entry with a path.
    If (zipEntry Is Nothing) Then
        Set zipEntry = zip.FirstMatchingEntry("*/dudeC.gif")
    End If
    
    If (zipEntry Is Nothing) Then
        MsgBox "Not found!"
    Else
        MsgBox "Found!"
    End If

 

Need a specific example? Send a request to support@chilkatsoft.com

© 2000-2008 Chilkat Software, Inc. All Rights Reserved.