home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic 4 Unleashed / Visual_Basic_4_Unleashed_SAMS_Publishing_1995.iso / source / chap04 / 04vbu04 / timertst.frm (.txt) next >
Encoding:
Visual Basic Form  |  1995-07-24  |  1.2 KB  |  44 lines

  1. VERSION 4.00
  2. Begin VB.Form Form1 
  3.    Caption         =   "Form1"
  4.    ClientHeight    =   1635
  5.    ClientLeft      =   60
  6.    ClientTop       =   1380
  7.    ClientWidth     =   3870
  8.    Height          =   2040
  9.    Left            =   0
  10.    LinkTopic       =   "Form1"
  11.    ScaleHeight     =   1635
  12.    ScaleWidth      =   3870
  13.    Top             =   1035
  14.    Width           =   3990
  15.    Begin VB.CommandButton Command1 
  16.       Cancel          =   -1  'True
  17.       Caption         =   "Close"
  18.       Height          =   405
  19.       Left            =   1530
  20.       TabIndex        =   0
  21.       Top             =   1155
  22.       Width           =   1215
  23.    End
  24.    Begin VB.Timer Timer1 
  25.       Interval        =   1000
  26.       Left            =   180
  27.       Top             =   1140
  28.    End
  29. Attribute VB_Name = "Form1"
  30. Attribute VB_Creatable = False
  31. Attribute VB_Exposed = False
  32. Option Explicit
  33. Private Sub Command1_Click()
  34.     End
  35. End Sub
  36. Private Sub Timer1_Timer()
  37.     Static sngLastTime As Single
  38.     Static sngCurrentTime As Single
  39.     sngCurrentTime = Timer
  40.     Me.Cls
  41.     Me.Print sngCurrentTime - sngLastTime
  42.     sngLastTime = sngCurrentTime
  43. End Sub
  44.