EnhCab.EnumerateCabinet

[This is preliminary documentation and subject to change.]

The EnumerateCabinet method counts the number of files stored within a cabinet file.

Syntax

object.EnumerateCabinet( sCab, lNumFiles )
 

Parts

object
Object expression that resolves to an EnhCab object.
sCab
String that contains the name of the cabinet file to enumerate.
lNumFiles
Long that receives the number of files in the cabinet.

QuickInfo

  Windows NT: Unsupported.
  Windows: Requires Windows 98.
  Windows CE: Unsupported.
  Header: Declared in ipenhsnd.idl.
  Import Library: Included as a resource in ipenhsnd.dll.
  Unicode: Yes.

See Also

EnhCab.FileName

Examples

The following example counts the number of files stored in the cabinet file, Cab1.cab.

Dim ecab As EnhCab
Set ecab = New EnhCab
 
'Create a variable to receive the file count.
Dim numFiles As Long
 
'Count the number of files in the cabinet and 
'store the value in the variable numFiles
ecab.EnumerateCabinet "C:\EnhancementFiles\Cab1.cab", numFiles
 
'Display a message box that informs the user of the file count
Msgbox "There are currently "+ CStr(numFile) + " files in the cabinet file."