home *** CD-ROM | disk | FTP | other *** search
/ Programmers Heaven 2 / Programmers Heaven 2.iso / files / windows / ocx / zipinf.exe / ZIPINFS2.FRM (.txt) < prev   
Encoding:
Visual Basic Form  |  1996-06-18  |  4.8 KB  |  168 lines

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