home *** CD-ROM | disk | FTP | other *** search
/ An Introduction to Progr…l Basic 6.0 (4th Edition) / An Introduction to Programming using Visual Basic 6.0.iso / PROGRAMS / CH10 / 10-4-2.FRM (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1998-09-21  |  1.5 KB  |  53 lines

  1. VERSION 5.00
  2. Begin VB.Form frm10_4_2 
  3.    Caption         =   "Sector"
  4.    ClientHeight    =   3672
  5.    ClientLeft      =   3120
  6.    ClientTop       =   1968
  7.    ClientWidth     =   3408
  8.    BeginProperty Font 
  9.       Name            =   "MS Sans Serif"
  10.       Size            =   7.8
  11.       Charset         =   0
  12.       Weight          =   700
  13.       Underline       =   0   'False
  14.       Italic          =   0   'False
  15.       Strikethrough   =   0   'False
  16.    EndProperty
  17.    LinkTopic       =   "Form1"
  18.    PaletteMode     =   1  'UseZOrder
  19.    ScaleHeight     =   3672
  20.    ScaleWidth      =   3408
  21.    Begin VB.PictureBox picOutput 
  22.       Height          =   2775
  23.       Left            =   240
  24.       ScaleHeight     =   2724
  25.       ScaleWidth      =   2844
  26.       TabIndex        =   1
  27.       Top             =   720
  28.       Width           =   2895
  29.    End
  30.    Begin VB.CommandButton cmdDraw 
  31.       Caption         =   "Draw Sector"
  32.       Height          =   495
  33.       Left            =   960
  34.       TabIndex        =   0
  35.       Top             =   120
  36.       Width           =   1455
  37.    End
  38. Attribute VB_Name = "frm10_4_2"
  39. Attribute VB_GlobalNameSpace = False
  40. Attribute VB_Creatable = False
  41. Attribute VB_PredeclaredId = True
  42. Attribute VB_Exposed = False
  43. Private Sub cmdDraw_Click()
  44.   Dim c As Single
  45.   picOutput.Cls
  46.   picOutput.Scale (-3, 3)-(3, -3)  'Specify coordinate system
  47.   c = 2 * 3.14159
  48.   a = 0.0000001
  49.   b = 0.4
  50.   'Draw sector with radius lines corresponding to 0 and .4
  51.   picOutput.Circle (0, 0), 2, , -a * c, -b * c
  52. End Sub
  53.