VERSION 5.00
Begin VB.Form Form1 
   Caption         =   "有个性的按钮"
   ClientHeight    =   3195
   ClientLeft      =   60
   ClientTop       =   345
   ClientWidth     =   4680
   LinkTopic       =   "Form1"
   ScaleHeight     =   3195
   ScaleWidth      =   4680
   StartUpPosition =   3  '窗口缺省
   Begin VB.CommandButton CmdStop 
      Caption         =   "停止"
      Height          =   495
      Left            =   3240
      TabIndex        =   2
      Top             =   720
      Width           =   855
   End
   Begin VB.CommandButton CmdDrog 
      Caption         =   "拖动"
      Height          =   495
      Left            =   3240
      TabIndex        =   1
      Top             =   120
      Width           =   855
   End
   Begin VB.CommandButton CmdMove 
      Height          =   1095
      Left            =   240
      Picture         =   "Form1.frx":0000
      Style           =   1  'Graphical
      TabIndex        =   0
      ToolTipText     =   "可移动的的按钮"
      Top             =   120
      Width           =   1215
   End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False


Private Sub CmdDrog_Click()
    CmdMove.DragMode = 1        '设置拖动模式为自动
    CmdMove.MousePointer = 15   '设置鼠标指针为移动指针样式
    CmdMove.Caption = "说走就走!"
End Sub



Private Sub CmdStop_Click()
    CmdMove.DragMode = 0        '设置拖动模式为手动
    CmdMove.Caption = "歇会儿,说什么也不走了!"
    CmdMove.MousePointer = 12   '设置鼠标指针为禁用指针样式
End Sub

Private Sub Form_DragDrop(Source As Control, X As Single, Y As Single)
    Source.Top = Y          '设置按钮对象的顶端位置
    Source.Left = X         '设置按钮对象的左端位置
End Sub

Private Sub Form_Load()
    CmdStop_Click       '调用CmdStop_Click()过程,设置CmdMove按钮的初始属性
End Sub
