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

📄 frmclean.frm

📁 餐饮茶馆管理系统
💻 FRM
字号:
VERSION 5.00
Object = "{0BA686C6-F7D3-101A-993E-0000C0EF6F5E}#1.0#0"; "THREED32.OCX"
Begin VB.Form frmClean 
   BorderStyle     =   3  'Fixed Dialog
   Caption         =   "系统重建选择"
   ClientHeight    =   3600
   ClientLeft      =   45
   ClientTop       =   330
   ClientWidth     =   6375
   Icon            =   "frmClean.frx":0000
   LinkTopic       =   "Form1"
   LockControls    =   -1  'True
   MaxButton       =   0   'False
   MinButton       =   0   'False
   ScaleHeight     =   3600
   ScaleWidth      =   6375
   ShowInTaskbar   =   0   'False
   StartUpPosition =   3  '窗口缺省
   Begin Threed.SSCommand cmdClean 
      Height          =   390
      Left            =   5025
      TabIndex        =   1
      Top             =   390
      Width           =   1080
      _Version        =   65536
      _ExtentX        =   1905
      _ExtentY        =   688
      _StockProps     =   78
      Caption         =   "清除(&C)"
      BevelWidth      =   1
   End
   Begin Threed.SSFrame SSFrame1 
      Height          =   3210
      Left            =   135
      TabIndex        =   0
      Top             =   240
      Width           =   4590
      _Version        =   65536
      _ExtentX        =   8096
      _ExtentY        =   5662
      _StockProps     =   14
      Caption         =   "请选定需要清除的项目"
      BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
         Name            =   "宋体"
         Size            =   9
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Font3D          =   3
      Begin VB.CheckBox chkPaymethod 
         Caption         =   "付款分类"
         Height          =   285
         Left            =   2535
         TabIndex        =   13
         Top             =   2139
         Width           =   1485
      End
      Begin VB.CheckBox chkUnit 
         Caption         =   "单位分类"
         Height          =   285
         Left            =   2535
         TabIndex        =   12
         Top             =   1706
         Width           =   1485
      End
      Begin VB.CheckBox chkTmp 
         Caption         =   "临时表"
         Height          =   285
         Left            =   2535
         TabIndex        =   11
         Top             =   1272
         Width           =   1485
      End
      Begin VB.CheckBox chkOperator 
         Caption         =   "操作员"
         Height          =   285
         Left            =   2535
         TabIndex        =   10
         Top             =   891
         Width           =   1485
      End
      Begin VB.CheckBox chkStore 
         Caption         =   "仓库详细信息"
         Height          =   240
         Left            =   2535
         TabIndex        =   9
         Top             =   547
         Width           =   1500
      End
      Begin VB.CheckBox chkCustomer 
         Caption         =   "消费详细信息"
         Height          =   315
         Left            =   510
         TabIndex        =   8
         Top             =   2505
         Width           =   2040
      End
      Begin VB.CheckBox chkEnter 
         Caption         =   "进货详细信息"
         Height          =   345
         Left            =   510
         TabIndex        =   7
         Top             =   2109
         Width           =   1590
      End
      Begin VB.CheckBox chkMember 
         Caption         =   "会员卡信息"
         Height          =   420
         Left            =   510
         TabIndex        =   6
         Top             =   1638
         Width           =   1305
      End
      Begin VB.CheckBox chkMenuDetail 
         Caption         =   "菜单详细信息"
         Height          =   345
         Left            =   510
         TabIndex        =   5
         Top             =   1242
         Width           =   1725
      End
      Begin VB.CheckBox chkMenu 
         Caption         =   "菜单分类"
         Height          =   315
         Left            =   510
         TabIndex        =   4
         Top             =   876
         Width           =   1320
      End
      Begin VB.CheckBox chkSite 
         Caption         =   "座位分类"
         Height          =   315
         Left            =   510
         TabIndex        =   3
         Top             =   510
         Width           =   1320
      End
   End
   Begin Threed.SSCommand cmdClose 
      Cancel          =   -1  'True
      Height          =   390
      Left            =   5025
      TabIndex        =   2
      Top             =   840
      Width           =   1080
      _Version        =   65536
      _ExtentX        =   1905
      _ExtentY        =   688
      _StockProps     =   78
      Caption         =   "退出(&X)"
      BevelWidth      =   1
   End
End
Attribute VB_Name = "frmClean"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub cmdClean_Click()
   
   If MsgBox("选定项目的所有数据都将消失,是否继续(Y/N)?   ", vbInformation + vbYesNo + vbDefaultButton2) = vbNo Then
      Exit Sub
    Else
      CleanSystem
   End If
  
End Sub

Private Sub cmdClose_Click()

  Unload Me
  
End Sub

Private Sub CleanSystem()

   Dim Db As Database, sTmp As String
   Set Db = OpenDatabase(ConData, False, False, Constr)
   
  '座位
      If chkSite.Value = vbChecked Then
         sTmp = "Delete * From SiteType"
      Db.Execute sTmp
      End If
 ' 菜单
      If chkMenu.Value = vbChecked Then
         sTmp = "Delete * From MenuType"
      Db.Execute sTmp
      End If
 ' 菜单详细
      If chkMenuDetail.Value = vbChecked Then
         sTmp = "Delete * From EatList"
      Db.Execute sTmp
      End If
 ' 会员卡信息
      If chkMember.Value = vbChecked Then
         sTmp = "Delete * From Detail"
      Db.Execute sTmp
      End If
 ' 进货
      If chkEnter.Value = vbChecked Then
         sTmp = "Delete * From EnterList"
      Db.Execute sTmp
      End If
 ' 消费
      If chkCustomer.Value = vbChecked Then
         sTmp = "Delete * From SellCount"
         Db.Execute sTmp
         sTmp = "Delete * From SellList"
         Db.Execute sTmp
      End If
 ' 仓库
       If chkStore.Value = vbChecked Then
         sTmp = "Delete * From StoreList"
         Db.Execute sTmp
      End If
 ' 操作员
      If chkOperator.Value = vbChecked Then
         sTmp = "Delete * From Main"
         Db.Execute sTmp
         sTmp = "Delete * From Authority"
         Db.Execute sTmp
         sTmp = "Insert into Main (操作员,口令) values('超级用户','')"
         Db.Execute sTmp
      End If
 ' 临时库
      If chkTmp.Value = vbChecked Then
         sTmp = "Delete * From tmpSell"
         Db.Execute sTmp
      End If
' 单位分类
      If chkUnit.Value = vbChecked Then
         sTmp = "Delete * From UnitType"
         Db.Execute sTmp
      End If
' 付款
      If chkPaymethod.Value = vbChecked Then
         sTmp = "Delete * From PayType"
         Db.Execute sTmp
      End If
      
   Db.Close
   
   MsgBox "清除工作已经完成,按《确定》退出。   ", vbInformation
   Unload Me
   
End Sub

Private Sub Form_Load()

   GetFormSet Me, Screen
   
End Sub

Private Sub Form_Unload(Cancel As Integer)

   SaveFormSet Me
   
End Sub

⌨️ 快捷键说明

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