home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / change4a / change.frm (.txt) next >
Encoding:
Visual Basic Form  |  1999-09-22  |  4.0 KB  |  127 lines

  1. VERSION 5.00
  2. Begin VB.Form Form1 
  3.    BackColor       =   &H80000007&
  4.    Caption         =   "Form1"
  5.    ClientHeight    =   5805
  6.    ClientLeft      =   60
  7.    ClientTop       =   345
  8.    ClientWidth     =   6570
  9.    LinkTopic       =   "Form1"
  10.    ScaleHeight     =   5805
  11.    ScaleWidth      =   6570
  12.    StartUpPosition =   3  'Windows Default
  13.    Begin VB.CommandButton cmdChange 
  14.       BackColor       =   &H00FF0000&
  15.       Caption         =   "Change &Width"
  16.       BeginProperty Font 
  17.          Name            =   "MS Sans Serif"
  18.          Size            =   8.25
  19.          Charset         =   0
  20.          Weight          =   700
  21.          Underline       =   0   'False
  22.          Italic          =   -1  'True
  23.          Strikethrough   =   0   'False
  24.       EndProperty
  25.       Height          =   495
  26.       Index           =   3
  27.       Left            =   2640
  28.       Style           =   1  'Graphical
  29.       TabIndex        =   3
  30.       Top             =   3480
  31.       Width           =   1215
  32.    End
  33.    Begin VB.CommandButton cmdChange 
  34.       BackColor       =   &H00FF0000&
  35.       Caption         =   "Change &Height"
  36.       BeginProperty Font 
  37.          Name            =   "MS Sans Serif"
  38.          Size            =   8.25
  39.          Charset         =   0
  40.          Weight          =   700
  41.          Underline       =   0   'False
  42.          Italic          =   -1  'True
  43.          Strikethrough   =   0   'False
  44.       EndProperty
  45.       Height          =   495
  46.       Index           =   2
  47.       Left            =   2640
  48.       Style           =   1  'Graphical
  49.       TabIndex        =   2
  50.       Top             =   2520
  51.       Width           =   1215
  52.    End
  53.    Begin VB.CommandButton cmdChange 
  54.       BackColor       =   &H00FF0000&
  55.       Caption         =   "Change &Bold"
  56.       BeginProperty Font 
  57.          Name            =   "MS Sans Serif"
  58.          Size            =   8.25
  59.          Charset         =   0
  60.          Weight          =   700
  61.          Underline       =   0   'False
  62.          Italic          =   -1  'True
  63.          Strikethrough   =   0   'False
  64.       EndProperty
  65.       Height          =   495
  66.       Index           =   1
  67.       Left            =   2640
  68.       Style           =   1  'Graphical
  69.       TabIndex        =   1
  70.       Top             =   1560
  71.       Width           =   1215
  72.    End
  73.    Begin VB.CommandButton cmdChange 
  74.       BackColor       =   &H00FF0000&
  75.       Caption         =   "Change &Color"
  76.       BeginProperty Font 
  77.          Name            =   "MS Sans Serif"
  78.          Size            =   8.25
  79.          Charset         =   0
  80.          Weight          =   700
  81.          Underline       =   0   'False
  82.          Italic          =   -1  'True
  83.          Strikethrough   =   0   'False
  84.       EndProperty
  85.       Height          =   495
  86.       Index           =   0
  87.       Left            =   2640
  88.       Style           =   1  'Graphical
  89.       TabIndex        =   0
  90.       Top             =   600
  91.       Width           =   1215
  92.    End
  93. Attribute VB_Name = "Form1"
  94. Attribute VB_GlobalNameSpace = False
  95. Attribute VB_Creatable = False
  96. Attribute VB_PredeclaredId = True
  97. Attribute VB_Exposed = False
  98. Private Sub cmdChange_Click(Index As Integer)
  99.   ' Changes ONLY the button clicked!So Remember That!
  100.   Select Case Index
  101.       Case 0:
  102.       If cmdChange.Item(Index).BackColor = vbRed Then
  103.          cmdChange.Item(Index).BackColor = vbBlue
  104.       Else
  105.          cmdChange.Item(Index).BackColor = vbRed
  106.       End If
  107.     Case 1:
  108.       If cmdChange.Item(Index).FontBold = True Then
  109.          cmdChange.Item(Index).FontBold = False
  110.       Else
  111.          cmdChange.Item(Index).FontBold = True
  112.       End If
  113.     Case 2:
  114.       If cmdChange.Item(Index).Height = 495 Then
  115.          cmdChange.Item(Index).Height = 595
  116.       Else
  117.          cmdChange.Item(Index).Height = 495
  118.       End If
  119.     Case 3:
  120.       If cmdChange.Item(Index).Width = 1215 Then
  121.          cmdChange.Item(Index).Width = 2000
  122.       Else
  123.          cmdChange.Item(Index).Width = 1215
  124.       End If
  125.     End Select
  126. End Sub
  127.