⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 frmdel.frm

📁 一个vb的mis系统
💻 FRM
字号:
VERSION 5.00
Begin VB.Form frmdel 
   BorderStyle     =   0  'None
   ClientHeight    =   3015
   ClientLeft      =   0
   ClientTop       =   0
   ClientWidth     =   6675
   LinkTopic       =   "Form1"
   Picture         =   "frmdel.frx":0000
   ScaleHeight     =   3015
   ScaleWidth      =   6675
   ShowInTaskbar   =   0   'False
   StartUpPosition =   2  '屏幕中心
   Begin VB.Timer mousemovetimer 
      Enabled         =   0   'False
      Interval        =   1
      Left            =   120
      Top             =   3000
   End
   Begin VB.OptionButton chk2 
      BackColor       =   &H00FFFFFF&
      Height          =   200
      Left            =   4320
      Style           =   1  'Graphical
      TabIndex        =   3
      Top             =   1950
      Visible         =   0   'False
      Width           =   200
   End
   Begin VB.OptionButton chk1 
      BackColor       =   &H00FFFFFF&
      Height          =   200
      Left            =   2280
      Style           =   1  'Graphical
      TabIndex        =   0
      Top             =   1950
      Value           =   -1  'True
      Visible         =   0   'False
      Width           =   200
   End
   Begin VB.Image pictemp2 
      Height          =   615
      Left            =   960
      Picture         =   "frmdel.frx":7E23C
      Stretch         =   -1  'True
      Top             =   3240
      Width           =   975
   End
   Begin VB.Image mousermovepic 
      Height          =   345
      Left            =   0
      Picture         =   "frmdel.frx":FC478
      Top             =   0
      Width           =   6675
   End
   Begin VB.Label txt3 
      BackStyle       =   0  'Transparent
      Caption         =   "     谢谢使用!"
      Height          =   615
      Left            =   2160
      TabIndex        =   4
      Top             =   1440
      Visible         =   0   'False
      Width           =   3735
   End
   Begin VB.Image picend 
      Height          =   285
      Left            =   4800
      Picture         =   "frmdel.frx":103CC4
      Top             =   2400
      Visible         =   0   'False
      Width           =   1065
   End
   Begin VB.Image pictemp 
      Height          =   615
      Left            =   2520
      Picture         =   "frmdel.frx":104D10
      Stretch         =   -1  'True
      Top             =   3240
      Width           =   975
   End
   Begin VB.Label txt2 
      BackStyle       =   0  'Transparent
      Caption         =   "    请选择是否保留用户信息。如果保留,下次安装将能继续使用上次的用户信息。"
      Height          =   615
      Left            =   2280
      TabIndex        =   2
      Top             =   1440
      Visible         =   0   'False
      Width           =   3735
   End
   Begin VB.Label txt1 
      BackStyle       =   0  'Transparent
      Caption         =   "    即将卸载ACCP学员管理系统,请确保已经断开所有数据连接并关闭相关的程序。准备好后请单击确定按钮。"
      Height          =   615
      Left            =   2280
      TabIndex        =   1
      Top             =   1440
      Width           =   3735
   End
   Begin VB.Image picok 
      Height          =   285
      Left            =   4800
      Picture         =   "frmdel.frx":182F4C
      Top             =   2400
      Width           =   1065
   End
   Begin VB.Image picexit 
      Height          =   285
      Left            =   3360
      Picture         =   "frmdel.frx":183F98
      Top             =   2400
      Width           =   1065
   End
   Begin VB.Image picdel 
      Height          =   285
      Left            =   4800
      Picture         =   "frmdel.frx":184FE4
      Top             =   2400
      Visible         =   0   'False
      Width           =   1065
   End
End
Attribute VB_Name = "frmdel"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim oldx As Integer      '为解决全图形窗口没有标题栏而无法拖动的问题而定义的鼠标新旧两个XY变量
Dim oldy As Integer
Dim newx As Integer
Dim newy As Integer

'>>>>>>>>>>>>>>>>>>>>>>>>以下程序段解决全图形窗口的移动问题<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
'移植须知:将该功能移植到一个全图片窗口以解决不能移动的问题时,需注意:1 赋值计时器和伪装标题栏到新的全图片窗体中;2 赋值定义的新旧XY值(4个)和本程序段到新的全图片窗体中;3 修改计时器的过程“mousemovetimer_Timer”中的四个窗体名字。4 修改伪装标题栏的图片
'当指定图片(伪装标题栏)被鼠标点击时启动计时器,并记录下当时的初始鼠标坐标
Private Sub mousermovepic_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    mousemovetimer.Enabled = True
    oldx = X
    oldy = Y
End Sub
'当指定图片(伪装标题栏)上鼠标移动时,赋给新的鼠标XY值,注意系统每隔很短的时间会赋值一次。
Private Sub mousermovepic_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
    newx = X
    newy = Y
End Sub
'当指定图片(伪装标题栏)被鼠标释放时关闭计时器。
Private Sub mousermovepic_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
    mousemovetimer.Enabled = False
End Sub
'计时器将定时得到四个值,分别是固定的初始XY值,和不断变化的新的XY值。利用新旧XY的差,可以以此来移动窗体。适当调小计时器间隔时间将有助于移动窗体的流畅性。
Private Sub mousemovetimer_Timer()
    frmdel.Left = frmdel.Left - (oldx - newx)
    If frmdel.Top - (oldy - newy) < 1050 Then
        frmdel.Top = 1050
    Else
        frmdel.Top = frmdel.Top - (oldy - newy)
    End If
End Sub
'>>>>>>>>>>>>>>>>>>>>>>>>以上程序段解决全图形窗口的移动问题<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<








Private Sub delall() '不保留用户信息,全部删除
    Dim fso As New FileSystemObject
    fso.DeleteFolder ("c:\program files\accp\help")
    fso.DeleteFolder ("C:\Documents and Settings\All Users\「开始」菜单\程序\ACCP学员管理系统")
    Kill "c:\program files\accp\*.*"
End Sub
Private Sub saveuser() '保存用户信息,其余删除
    Dim fso As New FileSystemObject
    fso.DeleteFolder ("c:\program files\accp\help")
    fso.DeleteFolder ("C:\Documents and Settings\All Users\「开始」菜单\程序\ACCP学员管理系统")
    Kill "c:\program files\accp\*.exe"
    Kill "c:\program files\accp\*.swf"
    Kill "c:\program files\accp\*.bak"
    Kill "c:\program files\accp\*.ico"
End Sub




'初始化窗体
Private Sub Form_Load()
    Me.Height = 3000
    Me.Width = 6675
End Sub



'卸载按钮
Private Sub picdel_Click()
    If chk1.Value = True Then
        Call saveuser
    Else
        Call delall
    End If
    txt2.Visible = False
    txt3.Visible = True
    picend.Visible = True
    Set Me.Picture = pictemp2.Picture
    chk1.Visible = False
    chk2.Visible = False
    picexit.Visible = False
End Sub

Private Sub picend_Click()
    Unload Me
End Sub

'取消按钮
Private Sub picexit_Click()
    Unload Me
End Sub

Private Sub picok_Click()
    txt1.Visible = False
    txt2.Visible = True
    picdel.Visible = True
    picok.Visible = False
    chk1.Visible = True
    chk2.Visible = True
    Set Me.Picture = pictemp.Picture
End Sub

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -