home *** CD-ROM | disk | FTP | other *** search
/ DP Tool Club 26 / CD_ASCQ_26_1295.iso / vrac / msmega.zip / ZIPINFSA.ZIP / ZSAMPLE2.FRM < prev   
Text File  |  1993-12-20  |  4KB  |  147 lines

  1. VERSION 2.00
  2. Begin Form ZSample2 
  3.    BorderStyle     =   3  'Fixed Double
  4.    Caption         =   "Open ZIP File"
  5.    ClientHeight    =   3270
  6.    ClientLeft      =   2715
  7.    ClientTop       =   3465
  8.    ClientWidth     =   7215
  9.    ControlBox      =   0   'False
  10.    Height          =   3675
  11.    Left            =   2655
  12.    LinkTopic       =   "Form1"
  13.    MaxButton       =   0   'False
  14.    MinButton       =   0   'False
  15.    ScaleHeight     =   3270
  16.    ScaleWidth      =   7215
  17.    Top             =   3120
  18.    Width           =   7335
  19.    Begin DriveListBox Drive1 
  20.       Height          =   315
  21.       Left            =   3000
  22.       TabIndex        =   4
  23.       Top             =   2760
  24.       Width           =   2535
  25.    End
  26.    Begin DirListBox Dir1 
  27.       Height          =   1605
  28.       Left            =   3000
  29.       TabIndex        =   8
  30.       Top             =   840
  31.       Width           =   2535
  32.    End
  33.    Begin FileListBox File1 
  34.       Height          =   2175
  35.       Left            =   240
  36.       Pattern         =   "*.ZIP"
  37.       TabIndex        =   5
  38.       Top             =   840
  39.       Width           =   2535
  40.    End
  41.    Begin TextBox Text1 
  42.       Height          =   285
  43.       Left            =   240
  44.       TabIndex        =   3
  45.       Top             =   480
  46.       Width           =   2535
  47.    End
  48.    Begin CommandButton Command2 
  49.       Caption         =   "Cancel"
  50.       Height          =   375
  51.       Left            =   5760
  52.       TabIndex        =   1
  53.       Top             =   720
  54.       Width           =   1215
  55.    End
  56.    Begin CommandButton Command1 
  57.       Caption         =   "OK"
  58.       Default         =   -1  'True
  59.       Height          =   375
  60.       Left            =   5760
  61.       TabIndex        =   0
  62.       Top             =   240
  63.       Width           =   1215
  64.    End
  65.    Begin Label Label4 
  66.       Caption         =   "Drives:"
  67.       Height          =   255
  68.       Left            =   3000
  69.       TabIndex        =   9
  70.       Top             =   2520
  71.       Width           =   1335
  72.    End
  73.    Begin Label Label3 
  74.       Height          =   255
  75.       Left            =   3000
  76.       TabIndex        =   7
  77.       Top             =   525
  78.       Width           =   2535
  79.    End
  80.    Begin Label Label2 
  81.       Caption         =   "Directories:"
  82.       Height          =   255
  83.       Left            =   3000
  84.       TabIndex        =   6
  85.       Top             =   240
  86.       Width           =   1335
  87.    End
  88.    Begin Label Label1 
  89.       Caption         =   "File Name:"
  90.       Height          =   255
  91.       Left            =   240
  92.       TabIndex        =   2
  93.       Top             =   240
  94.       Width           =   1335
  95.    End
  96. End
  97. Option Explicit
  98.  
  99. Sub Command1_Click ()
  100.     On Error GoTo ErrorHandle
  101.  
  102.     If Right$(Dir1.Path, 1) = "\" Then
  103.         ZSample.ZipInfo1.FileName = Dir1.Path + File1.FileName
  104.     Else
  105.         ZSample.ZipInfo1.FileName = Dir1.Path + "\" + File1.FileName
  106.     End If
  107.  
  108.     If ZSample.ZipInfo1.ListCount >= 0 Then
  109.         ZSample2.Hide
  110.     End If
  111.  
  112.     Exit Sub
  113.  
  114. ErrorHandle:
  115.     MsgBox Error$(Err), 48, "Open ZIP"
  116.     On Error Resume Next
  117.     Resume ExitError
  118.  
  119. ExitError:
  120. End Sub
  121.  
  122. Sub Command2_Click ()
  123.     ZSample2.Hide
  124. End Sub
  125.  
  126. Sub Dir1_Change ()
  127.     Label3.Caption = Dir1.Path
  128.     File1.Path = Dir1.Path
  129. End Sub
  130.  
  131. Sub Drive1_Change ()
  132.     Dir1.Path = Drive1.Drive
  133. End Sub
  134.  
  135. Sub File1_Click ()
  136.     Text1.Text = File1.FileName
  137. End Sub
  138.  
  139. Sub File1_DblClick ()
  140.     Command1_Click
  141. End Sub
  142.  
  143. Sub Form_Load ()
  144.     Label3.Caption = Dir1.Path
  145. End Sub
  146.  
  147.