home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Controls / Visual Basic Controls.iso / vbcontrol / swbclbtn / form1.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1999-06-27  |  7.6 KB  |  242 lines

  1. VERSION 5.00
  2. Object = "{D5A04443-2C88-11D3-A119-0080C6F7AC86}#2.0#0"; "SWBCOOLBTN.OCX"
  3. Begin VB.Form Form1 
  4.    BorderStyle     =   1  'Fixed Single
  5.    Caption         =   "SWBCoolButton Sample Project"
  6.    ClientHeight    =   4395
  7.    ClientLeft      =   45
  8.    ClientTop       =   330
  9.    ClientWidth     =   6495
  10.    KeyPreview      =   -1  'True
  11.    LinkTopic       =   "Form1"
  12.    MaxButton       =   0   'False
  13.    MinButton       =   0   'False
  14.    ScaleHeight     =   4395
  15.    ScaleWidth      =   6495
  16.    StartUpPosition =   2  'CenterScreen
  17.    Begin VB.CheckBox chkShowFocus 
  18.       Caption         =   "Show Focus"
  19.       Height          =   195
  20.       Left            =   3060
  21.       TabIndex        =   3
  22.       Top             =   3210
  23.       Width           =   1785
  24.    End
  25.    Begin VB.CheckBox chkEnabled 
  26.       Caption         =   "Buttons Enabled"
  27.       Height          =   255
  28.       Left            =   3060
  29.       TabIndex        =   2
  30.       Top             =   2880
  31.       Value           =   1  'Checked
  32.       Width           =   1635
  33.    End
  34.    Begin VB.Frame Frame2 
  35.       Height          =   3585
  36.       Left            =   90
  37.       TabIndex        =   0
  38.       Top             =   660
  39.       Width           =   1245
  40.       Begin SWBCoolBtnCtl.SWBCoolBtn cmdSet1 
  41.          Height          =   795
  42.          Index           =   0
  43.          Left            =   150
  44.          TabIndex        =   5
  45.          Top             =   240
  46.          Width           =   915
  47.          _ExtentX        =   1614
  48.          _ExtentY        =   1402
  49.          Caption         =   "&New"
  50.          MaskColor       =   12632256
  51.          Picture         =   "Form1.frx":0000
  52.          PictureHot      =   "Form1.frx":067A
  53.       End
  54.       Begin SWBCoolBtnCtl.SWBCoolBtn cmdSet1 
  55.          Height          =   795
  56.          Index           =   1
  57.          Left            =   150
  58.          TabIndex        =   6
  59.          Top             =   1050
  60.          Width           =   915
  61.          _ExtentX        =   1614
  62.          _ExtentY        =   1402
  63.          Caption         =   "&Open"
  64.          MaskColor       =   12632256
  65.          Picture         =   "Form1.frx":0CF4
  66.          PictureHot      =   "Form1.frx":136E
  67.       End
  68.       Begin SWBCoolBtnCtl.SWBCoolBtn cmdSet1 
  69.          Height          =   795
  70.          Index           =   2
  71.          Left            =   150
  72.          TabIndex        =   7
  73.          Top             =   1860
  74.          Width           =   915
  75.          _ExtentX        =   1614
  76.          _ExtentY        =   1402
  77.          Caption         =   "&Save"
  78.          MaskColor       =   12632256
  79.          Picture         =   "Form1.frx":19E8
  80.          PictureHot      =   "Form1.frx":2062
  81.       End
  82.       Begin SWBCoolBtnCtl.SWBCoolBtn cmdSet1 
  83.          Height          =   795
  84.          Index           =   3
  85.          Left            =   150
  86.          TabIndex        =   8
  87.          Top             =   2670
  88.          Width           =   915
  89.          _ExtentX        =   1614
  90.          _ExtentY        =   1402
  91.          Caption         =   "&Print"
  92.          MaskColor       =   12632256
  93.          Picture         =   "Form1.frx":26DC
  94.          PictureHot      =   "Form1.frx":2D56
  95.       End
  96.    End
  97.    Begin SWBCoolBtnCtl.SWBCoolBtn cmdExit 
  98.       Height          =   375
  99.       Left            =   5070
  100.       TabIndex        =   4
  101.       Top             =   3870
  102.       Width           =   1275
  103.       _ExtentX        =   2249
  104.       _ExtentY        =   661
  105.       Caption         =   "E&xit"
  106.       CaptionPos      =   3
  107.       MaskColor       =   12632256
  108.    End
  109.    Begin VB.Frame Frame1 
  110.       Height          =   45
  111.       Left            =   -30
  112.       TabIndex        =   1
  113.       Top             =   420
  114.       Width           =   6855
  115.    End
  116.    Begin SWBCoolBtnCtl.SWBCoolBtn cmdSet2 
  117.       Height          =   375
  118.       Index           =   0
  119.       Left            =   30
  120.       TabIndex        =   11
  121.       Top             =   30
  122.       Width           =   1275
  123.       _ExtentX        =   2249
  124.       _ExtentY        =   661
  125.       Caption         =   "Spell &Check"
  126.       CaptionPos      =   2
  127.       MaskColor       =   12632256
  128.       Picture         =   "Form1.frx":33D0
  129.       PictureHot      =   "Form1.frx":3912
  130.    End
  131.    Begin SWBCoolBtnCtl.SWBCoolBtn cmdSet2 
  132.       Height          =   375
  133.       Index           =   1
  134.       Left            =   1320
  135.       TabIndex        =   12
  136.       Top             =   30
  137.       Width           =   1275
  138.       _ExtentX        =   2249
  139.       _ExtentY        =   661
  140.       Caption         =   "Pre&view"
  141.       CaptionPos      =   2
  142.       MaskColor       =   12632256
  143.       Picture         =   "Form1.frx":3E54
  144.       PictureHot      =   "Form1.frx":4396
  145.    End
  146.    Begin SWBCoolBtnCtl.SWBCoolBtn cmdSet2 
  147.       Height          =   375
  148.       Index           =   2
  149.       Left            =   2610
  150.       TabIndex        =   13
  151.       Top             =   30
  152.       Width           =   1275
  153.       _ExtentX        =   2249
  154.       _ExtentY        =   661
  155.       Caption         =   "P&aint"
  156.       CaptionPos      =   2
  157.       MaskColor       =   12632256
  158.       Picture         =   "Form1.frx":48D8
  159.       PictureHot      =   "Form1.frx":4E1A
  160.    End
  161.    Begin SWBCoolBtnCtl.SWBCoolBtn cmdSet2 
  162.       Height          =   375
  163.       Index           =   3
  164.       Left            =   3900
  165.       TabIndex        =   14
  166.       Top             =   30
  167.       Width           =   1275
  168.       _ExtentX        =   2249
  169.       _ExtentY        =   661
  170.       Caption         =   "&Undo"
  171.       CaptionPos      =   2
  172.       MaskColor       =   12632256
  173.       Picture         =   "Form1.frx":535C
  174.       PictureHot      =   "Form1.frx":589E
  175.    End
  176.    Begin SWBCoolBtnCtl.SWBCoolBtn cmdSet2 
  177.       Height          =   375
  178.       Index           =   4
  179.       Left            =   5190
  180.       TabIndex        =   15
  181.       Top             =   30
  182.       Width           =   1275
  183.       _ExtentX        =   2249
  184.       _ExtentY        =   661
  185.       Caption         =   "&Help"
  186.       CaptionPos      =   2
  187.       MaskColor       =   12632256
  188.       Picture         =   "Form1.frx":5DE0
  189.       PictureHot      =   "Form1.frx":6322
  190.    End
  191.    Begin VB.Label Label1 
  192.       AutoSize        =   -1  'True
  193.       Caption         =   "Last Button Clicked:"
  194.       Height          =   195
  195.       Left            =   3120
  196.       TabIndex        =   10
  197.       Top             =   1920
  198.       Width           =   1425
  199.    End
  200.    Begin VB.Label lblClick 
  201.       BorderStyle     =   1  'Fixed Single
  202.       Height          =   315
  203.       Left            =   3120
  204.       TabIndex        =   9
  205.       Top             =   2130
  206.       Width           =   1485
  207.    End
  208. Attribute VB_Name = "Form1"
  209. Attribute VB_GlobalNameSpace = False
  210. Attribute VB_Creatable = False
  211. Attribute VB_PredeclaredId = True
  212. Attribute VB_Exposed = False
  213. Option Explicit
  214. Private Sub chkEnabled_Click()
  215.     Dim I As Integer
  216.     For I = 0 To cmdSet1.UBound
  217.         cmdSet1(I).Enabled = (chkEnabled = vbChecked)
  218.     Next I
  219.     For I = 0 To cmdSet2.UBound
  220.         cmdSet2(I).Enabled = (chkEnabled = vbChecked)
  221.     Next I
  222. End Sub
  223. Private Sub chkShowFocus_Click()
  224.     Dim I As Integer
  225.     For I = 0 To cmdSet1.UBound
  226.         cmdSet1(I).ShowFocus = (chkShowFocus = vbChecked)
  227.     Next I
  228.     For I = 0 To cmdSet2.UBound
  229.         cmdSet2(I).ShowFocus = (chkShowFocus = vbChecked)
  230.     Next I
  231.     cmdSet1(0).SetFocus
  232. End Sub
  233. Private Sub cmdExit_Click()
  234.     Unload Me
  235. End Sub
  236. Private Sub cmdSet1_Click(Index As Integer)
  237.     lblClick.Caption = cmdSet1(Index).Caption
  238. End Sub
  239. Private Sub cmdSet2_Click(Index As Integer)
  240.     lblClick.Caption = cmdSet2(Index).Caption
  241. End Sub
  242.