home *** CD-ROM | disk | FTP | other *** search
/ Programming Tool Box / SIMS_2.iso / vb_code2 / tk_bar / tkabt.frm < prev    next >
Text File  |  1993-12-07  |  5KB  |  190 lines

  1. VERSION 2.00
  2. Begin Form frmAbout 
  3.    BackColor       =   &H00808080&
  4.    BorderStyle     =   1  'Fixed Single
  5.    Caption         =   "About"
  6.    ClientHeight    =   2685
  7.    ClientLeft      =   1140
  8.    ClientTop       =   1620
  9.    ClientWidth     =   3975
  10.    Height          =   3120
  11.    Left            =   1065
  12.    LinkTopic       =   "Form1"
  13.    MaxButton       =   0   'False
  14.    MinButton       =   0   'False
  15.    ScaleHeight     =   2685
  16.    ScaleWidth      =   3975
  17.    Top             =   1260
  18.    Width           =   4125
  19.    Begin Timer Timer1 
  20.       Interval        =   150
  21.       Left            =   2280
  22.       Top             =   3120
  23.    End
  24.    Begin PictureClip PicClip1 
  25.       Cols            =   4
  26.       Location        =   "1920,480,2940,240"
  27.       Picture         =   TKABT.FRX:0000
  28.    End
  29.    Begin PictureBox picInfo 
  30.       BackColor       =   &H00C0C0C0&
  31.       Height          =   990
  32.       Left            =   150
  33.       ScaleHeight     =   960
  34.       ScaleWidth      =   3660
  35.       TabIndex        =   0
  36.       Top             =   825
  37.       Width           =   3690
  38.       Begin Label lblLine2 
  39.          AutoSize        =   -1  'True
  40.          BackColor       =   &H00C0C0C0&
  41.          Caption         =   "Light at the End of the Tunnel Software"
  42.          ForeColor       =   &H00FF0000&
  43.          Height          =   195
  44.          Left            =   150
  45.          TabIndex        =   1
  46.          Top             =   300
  47.          Width           =   3390
  48.       End
  49.       Begin Label lblLine3 
  50.          AutoSize        =   -1  'True
  51.          BackColor       =   &H00C0C0C0&
  52.          Caption         =   "by Tim Koffley [70334,16]"
  53.          ForeColor       =   &H00000000&
  54.          Height          =   195
  55.          Left            =   750
  56.          TabIndex        =   2
  57.          Top             =   675
  58.          Width           =   2190
  59.       End
  60.       Begin Label lblLine1 
  61.          AutoSize        =   -1  'True
  62.          BackColor       =   &H00C0C0C0&
  63.          Caption         =   "Another Button Bar 1.0a"
  64.          ForeColor       =   &H00000000&
  65.          Height          =   195
  66.          Left            =   780
  67.          TabIndex        =   4
  68.          Top             =   75
  69.          Width           =   2070
  70.       End
  71.    End
  72.    Begin SSPanel pnlInfo 
  73.       BackColor       =   &H00C0C0C0&
  74.       BevelInner      =   1  'Inset
  75.       Font3D          =   0  'None
  76.       Height          =   2715
  77.       Left            =   0
  78.       TabIndex        =   3
  79.       Top             =   0
  80.       Width           =   3990
  81.       Begin CommandButton cmdOK 
  82.          BackColor       =   &H00000000&
  83.          Caption         =   "OK"
  84.          Default         =   -1  'True
  85.          Height          =   465
  86.          Left            =   1125
  87.          TabIndex        =   5
  88.          Top             =   2025
  89.          Width           =   1440
  90.       End
  91.       Begin PictureBox picIcon 
  92.          AutoSize        =   -1  'True
  93.          ClipControls    =   0   'False
  94.          Height          =   510
  95.          Left            =   1575
  96.          ScaleHeight     =   480
  97.          ScaleWidth      =   480
  98.          TabIndex        =   6
  99.          Top             =   225
  100.          Width           =   510
  101.       End
  102.    End
  103. End
  104. Option Explicit
  105.  
  106. Dim Shared sLeft1%, sLeft2%, sLeft3%
  107. Dim Shared sCurrPic As Integer
  108.  
  109. Sub cmdOk_Click ()
  110.   Unload Me
  111. End Sub
  112.  
  113. Sub Form_Activate ()
  114. Dim i%
  115.    '
  116.    ' i tried hooking the scrolling into a timer but
  117.    ' the effect was jerky animation so i just left it
  118.    ' as is with the scroll speed depending on machine
  119.    ' speed
  120.    '
  121.    'scroll the lines onto the screen
  122.    Timer1.Enabled = False
  123.    Refresh
  124.    For i = lblLine1.Left To sLeft1 Step 30
  125.       lblLine1.Left = i
  126.    Next
  127.    For i = lblLine2.Left To sLeft2 Step -30
  128.       lblLine2.Left = i
  129.    Next
  130.    For i = lblLine3.Left To sLeft3 Step 30
  131.       lblLine3.Left = i
  132.    Next
  133.    Timer1.Enabled = True
  134.  
  135. End Sub
  136.  
  137. Sub Form_Load ()
  138.  
  139. Dim Middle%
  140.  
  141.   picInfo.BorderStyle = 0
  142.  
  143.   CenterForm Me
  144.  
  145.   'fit panel to form
  146.   pnlInfo.Top = 0
  147.   pnlInfo.Left = 0
  148.   pnlInfo.Width = frmAbout.ScaleWidth
  149.   pnlInfo.Height = frmAbout.ScaleHeight
  150.  
  151.   'center form controls
  152.   Middle = (frmAbout.ScaleWidth / 2)
  153.   picIcon.Left = Middle - (picIcon.Width) / 2
  154.   picInfo.Left = Middle - (picInfo.Width) / 2
  155.   cmdOK.Left = Middle - (cmdOK.Width) / 2
  156.  
  157.   'save old line positions
  158.   sLeft1 = lblLine1.Left
  159.   sLeft2 = lblLine2.Left
  160.   sLeft3 = lblLine3.Left
  161.  
  162.   'move them off screen
  163.   lblLine1.Left = -lblLine1.Width - 1000
  164.   lblLine2.Left = lblLine2.Width + 1000
  165.   lblLine3.Left = -lblLine3.Width - 1000
  166.  
  167.   picIcon.Picture = PicClip1.GraphicCell(0)
  168.   sCurrPic = 0
  169.  
  170. End Sub
  171.  
  172. Sub Timer1_Timer ()
  173.    Select Case sCurrPic
  174.       Case 0
  175.          picIcon.Picture = PicClip1.GraphicCell(1)
  176.          sCurrPic = 1
  177.       Case 1
  178.          picIcon.Picture = PicClip1.GraphicCell(2)
  179.          sCurrPic = 2
  180.       Case 2
  181.          picIcon.Picture = PicClip1.GraphicCell(3)
  182.          sCurrPic = 3
  183.       Case 3
  184.          picIcon.Picture = PicClip1.GraphicCell(0)
  185.          sCurrPic = 0
  186.    End Select
  187.  
  188. End Sub
  189.  
  190.