home *** CD-ROM | disk | FTP | other *** search
/ Mastering Visual Basic 5 / MasteringVisualBasic5.iso / ch_code / ch05 / inches / inches.frm (.txt) next >
Encoding:
Visual Basic Form  |  1997-02-20  |  3.3 KB  |  106 lines

  1. VERSION 5.00
  2. Object = "{6B7E6392-850A-101B-AFC0-4210102A8DA7}#1.1#0"; "COMCTL32.OCX"
  3. Begin VB.Form Form1 
  4.    Caption         =   "Slider Demo 2"
  5.    ClientHeight    =   1890
  6.    ClientLeft      =   60
  7.    ClientTop       =   345
  8.    ClientWidth     =   4695
  9.    LinkTopic       =   "Form1"
  10.    ScaleHeight     =   1890
  11.    ScaleWidth      =   4695
  12.    StartUpPosition =   3  'Windows Default
  13.    Begin ComctlLib.Slider Slider1 
  14.       Height          =   495
  15.       Left            =   120
  16.       TabIndex        =   0
  17.       Top             =   540
  18.       Width           =   4275
  19.       _ExtentX        =   7541
  20.       _ExtentY        =   873
  21.       MouseIcon       =   "Inches.frx":0000
  22.       Max             =   50
  23.       SelectRange     =   -1  'True
  24.       TickFrequency   =   5
  25.    End
  26.    Begin VB.Label Label4 
  27.       Caption         =   "10"
  28.       BeginProperty Font 
  29.          Name            =   "Verdana"
  30.          Size            =   9.75
  31.          Charset         =   0
  32.          Weight          =   700
  33.          Underline       =   0   'False
  34.          Italic          =   0   'False
  35.          Strikethrough   =   0   'False
  36.       EndProperty
  37.       Height          =   270
  38.       Left            =   4125
  39.       TabIndex        =   4
  40.       Top             =   1095
  41.       Width           =   300
  42.    End
  43.    Begin VB.Label Label3 
  44.       Caption         =   "5"
  45.       BeginProperty Font 
  46.          Name            =   "Verdana"
  47.          Size            =   9.75
  48.          Charset         =   0
  49.          Weight          =   700
  50.          Underline       =   0   'False
  51.          Italic          =   0   'False
  52.          Strikethrough   =   0   'False
  53.       EndProperty
  54.       Height          =   270
  55.       Left            =   2205
  56.       TabIndex        =   3
  57.       Top             =   1095
  58.       Width           =   300
  59.    End
  60.    Begin VB.Label Label2 
  61.       Caption         =   "0"
  62.       BeginProperty Font 
  63.          Name            =   "Verdana"
  64.          Size            =   9.75
  65.          Charset         =   0
  66.          Weight          =   700
  67.          Underline       =   0   'False
  68.          Italic          =   0   'False
  69.          Strikethrough   =   0   'False
  70.       EndProperty
  71.       Height          =   270
  72.       Left            =   285
  73.       TabIndex        =   2
  74.       Top             =   1095
  75.       Width           =   300
  76.    End
  77.    Begin VB.Label Label1 
  78.       Caption         =   "Length in inches = 0"
  79.       BeginProperty Font 
  80.          Name            =   "Verdana"
  81.          Size            =   9
  82.          Charset         =   0
  83.          Weight          =   400
  84.          Underline       =   0   'False
  85.          Italic          =   0   'False
  86.          Strikethrough   =   0   'False
  87.       EndProperty
  88.       Height          =   315
  89.       Left            =   270
  90.       TabIndex        =   1
  91.       Top             =   60
  92.       Width           =   2685
  93.    End
  94. Attribute VB_Name = "Form1"
  95. Attribute VB_GlobalNameSpace = False
  96. Attribute VB_Creatable = False
  97. Attribute VB_PredeclaredId = True
  98. Attribute VB_Exposed = False
  99. Option Explicit
  100. Private Sub Slider1_Change()
  101.     Label1.Caption = "Length in inches = " & Format(Slider1.Value / 5, "#.00")
  102. End Sub
  103. Private Sub Slider1_Scroll()
  104.     Label1.Caption = "Length in inches = " & Format(Slider1.Value / 5, "#.00")
  105. End Sub
  106.