www.pudn.com > striptxt.zip > MAIN.FRM, change:1995-11-21,size:3577b


VERSION 2.00 
Begin Form frmMain  
   BackColor       =   &H8000000F& 
   BorderStyle     =   3  'Fixed Double 
   Caption         =   "StripText" 
   ClientHeight    =   1875 
   ClientLeft      =   1095 
   ClientTop       =   1485 
   ClientWidth     =   5925 
   Height          =   2280 
   Icon            =   MAIN.FRX:0000 
   Left            =   1035 
   LinkTopic       =   "Form1" 
   ScaleHeight     =   1875 
   ScaleWidth      =   5925 
   Top             =   1140 
   Width           =   6045 
   Begin CommandButton cmdAbout  
      Caption         =   "&About..." 
      Height          =   375 
      Left            =   2520 
      TabIndex        =   6 
      Top             =   1320 
      Width           =   1095 
   End 
   Begin CommandButton cmdQuit  
      Cancel          =   -1  'True 
      Caption         =   "Quit" 
      Height          =   375 
      Left            =   1320 
      TabIndex        =   5 
      Top             =   1320 
      Width           =   1095 
   End 
   Begin Ctl3D Ctl3D1  
      ClassList       =   MAIN.FRX:0302 
      Left            =   5400 
      Top             =   1320 
   End 
   Begin CommonDialog dlgFileOpen  
      CancelError     =   -1  'True 
      DefaultExt      =   "htm" 
      DialogTitle     =   "Open HTML source" 
      Filename        =   "*.htm" 
      Filter          =   "HTML files (*.htm)|*,htm|All files (*.*)|*.*" 
      Left            =   6000 
      Top             =   240 
   End 
   Begin CommandButton cmdBrowse  
      Caption         =   "Browse..." 
      Height          =   375 
      Left            =   4440 
      TabIndex        =   3 
      Top             =   840 
      Width           =   1335 
   End 
   Begin CommandButton cmdStripFile  
      Caption         =   "Strip..." 
      Default         =   -1  'True 
      Enabled         =   0   'False 
      Height          =   375 
      Left            =   120 
      TabIndex        =   2 
      Top             =   1320 
      Width           =   1095 
   End 
   Begin TextBox txtFile  
      Height          =   285 
      Left            =   120 
      TabIndex        =   1 
      Top             =   480 
      Width           =   5655 
   End 
   Begin Label lblStatus  
      BackColor       =   &H8000000F& 
      Height          =   255 
      Left            =   120 
      TabIndex        =   4 
      Top             =   960 
      Width           =   4215 
   End 
   Begin Label Label1  
      BackColor       =   &H8000000F& 
      Caption         =   "Which file do you want to strip:" 
      Height          =   255 
      Left            =   120 
      TabIndex        =   0 
      Top             =   240 
      Width           =   2895 
   End 
End 
Option Explicit 
 
Sub cmdAbout_Click () 
 
   frmAbout.Show 1 
 
End Sub 
 
Sub cmdBrowse_Click () 
 
   On Error Resume Next 
    
   ' Set up the common dialog 
   dlgFileOpen.Filename = "*.htm" 
    
   ' Show the common dialog 
   dlgFileOpen.Action = 1 
 
   ' If there was an error (the user pressed Cancel), 
   ' we exit 
   If Err Then Exit Sub 
    
   ' Show the filename in the textbox 
   txtFile = dlgFileOpen.Filename 
 
End Sub 
 
Sub cmdQuit_Click () 
 
   End 
 
End Sub 
 
Sub cmdStripFile_Click () 
 
   StripText CStr(txtFile) 
 
End Sub 
 
Sub Form_Load () 
 
   ' Center the form 
   Move (Screen.Width - Width) / 2, (Screen.Height - Height) / 2 
 
   ' Make the form redraw before the file dialog opens 
   Show 
 
End Sub 
 
Sub txtFile_Change () 
 
   cmdStripFile.Enabled = Not (txtFile = "") 
 
End Sub