VERSION 5.00
Begin VB.Form Form1 
   Caption         =   "VB6 例10-13  Line方法绘制积分面积图"
   ClientHeight    =   2760
   ClientLeft      =   60
   ClientTop       =   345
   ClientWidth     =   5385
   LinkTopic       =   "Form1"
   ScaleHeight     =   2760
   ScaleWidth      =   5385
   StartUpPosition =   3  '窗口缺省
   Begin VB.CommandButton Command1 
      Caption         =   "绘图"
      Height          =   495
      Left            =   4440
      TabIndex        =   3
      Top             =   1980
      Width           =   795
   End
   Begin VB.TextBox Text2 
      Height          =   375
      Left            =   4440
      TabIndex        =   2
      Text            =   "2"
      Top             =   1440
      Width           =   735
   End
   Begin VB.TextBox Text1 
      Height          =   375
      Left            =   4440
      TabIndex        =   1
      Text            =   "-1"
      Top             =   960
      Width           =   735
   End
   Begin VB.PictureBox Picture1 
      Height          =   2595
      Left            =   60
      ScaleHeight     =   2535
      ScaleWidth      =   3975
      TabIndex        =   0
      Top             =   0
      Width           =   4035
   End
   Begin VB.Label Label1 
      Caption         =   "上下限"
      Height          =   315
      Left            =   4500
      TabIndex        =   4
      Top             =   540
      Width           =   675
   End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
    Dim a, b
    a = Val(Text1): b = Val(Text2)
    Picture1.Scale (a - 1, b * b + 1)-(b + 1, -1)
    Picture1.Cls
    Picture1.Line (a - 1, 0)-(b + 1, 0)                  ' 画坐标轴
    Picture1.Line (0, -1)-(0, b * b + 1)
    For i = a To b Step 0.01
        Picture1.Line (i, 0)-(i, i * i)
    Next i
End Sub

