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

📄 form2.frm

📁 汽修厂管理软件
💻 FRM
📖 第 1 页 / 共 2 页
字号:
VERSION 5.00
Object = "{5E9E78A0-531B-11CF-91F6-C2863C385E30}#1.0#0"; "MSFLXGRD.OCX"
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
Begin VB.Form Frm_TimesCard 
   Caption         =   "洗车美容"
   ClientHeight    =   8715
   ClientLeft      =   3075
   ClientTop       =   1845
   ClientWidth     =   10455
   Icon            =   "Form2.frx":0000
   LinkTopic       =   "Form2"
   MaxButton       =   0   'False
   ScaleHeight     =   8715
   ScaleWidth      =   10455
   Begin VB.Frame Frame1 
      Height          =   5655
      Index           =   2
      Left            =   600
      TabIndex        =   8
      Top             =   1320
      Width           =   9135
      Begin VB.CommandButton Cmd_ResumeExit 
         Caption         =   "退出"
         Height          =   375
         Left            =   6720
         TabIndex        =   25
         Top             =   4080
         Width           =   1455
      End
      Begin VB.CommandButton Cmd_Gift 
         Caption         =   "赠送一次"
         Height          =   375
         Left            =   6600
         TabIndex        =   24
         Top             =   1200
         Width           =   1455
      End
      Begin VB.CommandButton Cmd_Usecard 
         Caption         =   "消费一次"
         Height          =   375
         Left            =   6600
         TabIndex        =   10
         Top             =   720
         Width           =   1455
      End
      Begin MSFlexGridLib.MSFlexGrid Grid_Resumed 
         Height          =   3855
         Left            =   600
         TabIndex        =   9
         Top             =   720
         Width           =   5415
         _ExtentX        =   9551
         _ExtentY        =   6800
         _Version        =   393216
         SelectionMode   =   1
      End
   End
   Begin VB.Frame Frame1 
      Height          =   5175
      Index           =   1
      Left            =   600
      TabIndex        =   7
      Top             =   1320
      Width           =   9135
      Begin VB.CommandButton Cmd_ExitBuy 
         Caption         =   "退出"
         Height          =   255
         Left            =   4320
         TabIndex        =   23
         Top             =   4680
         Width           =   1215
      End
      Begin VB.CommandButton Cmd_BuyCard 
         Caption         =   "确定"
         Height          =   255
         Left            =   840
         TabIndex        =   22
         Top             =   4680
         Width           =   1335
      End
      Begin VB.TextBox Txt_CardSum 
         Alignment       =   1  'Right Justify
         Height          =   270
         Left            =   960
         TabIndex        =   20
         Top             =   4200
         Width           =   975
      End
      Begin MSFlexGridLib.MSFlexGrid Grid_Selected 
         Height          =   3255
         Left            =   6240
         TabIndex        =   18
         Top             =   720
         Width           =   2655
         _ExtentX        =   4683
         _ExtentY        =   5741
         _Version        =   393216
         SelectionMode   =   1
      End
      Begin MSFlexGridLib.MSFlexGrid Grid_MeiROng 
         Height          =   3255
         Left            =   240
         TabIndex        =   17
         Top             =   720
         Width           =   4695
         _ExtentX        =   8281
         _ExtentY        =   5741
         _Version        =   393216
         SelectionMode   =   1
      End
      Begin VB.CommandButton Cmd_Del 
         Caption         =   "<=="
         Height          =   375
         Left            =   5280
         TabIndex        =   12
         Top             =   2040
         Width           =   735
      End
      Begin VB.CommandButton Cmd_Add 
         Caption         =   "==>"
         Height          =   375
         Left            =   5280
         TabIndex        =   11
         Top             =   1200
         Width           =   735
      End
      Begin VB.Label Label2 
         Caption         =   "元"
         Height          =   255
         Left            =   2160
         TabIndex        =   21
         Top             =   4200
         Width           =   375
      End
      Begin VB.Label Label1 
         Caption         =   "金额:"
         Height          =   255
         Left            =   240
         TabIndex        =   19
         Top             =   4200
         Width           =   615
      End
   End
   Begin VB.Frame Frame1 
      Height          =   5655
      Index           =   0
      Left            =   600
      TabIndex        =   3
      Top             =   1320
      Width           =   8295
      Begin VB.CommandButton Cmd_Cancel 
         Caption         =   "退出"
         Height          =   375
         Left            =   2520
         TabIndex        =   16
         Top             =   4920
         Width           =   1215
      End
      Begin VB.CommandButton Cmd_Ok 
         Caption         =   "确定"
         Height          =   375
         Left            =   600
         TabIndex        =   15
         Top             =   4920
         Width           =   1335
      End
      Begin VB.TextBox Txt_Sum 
         Height          =   270
         Left            =   1320
         Locked          =   -1  'True
         TabIndex        =   13
         Text            =   "0"
         Top             =   840
         Width           =   1215
      End
      Begin VB.TextBox Txt_CleanPrice 
         Height          =   270
         Index           =   0
         Left            =   2040
         TabIndex        =   5
         Text            =   "Text1"
         Top             =   240
         Width           =   1935
      End
      Begin VB.CheckBox Chk_Clean 
         Caption         =   "Check1"
         Height          =   255
         Index           =   0
         Left            =   480
         TabIndex        =   4
         Top             =   240
         Width           =   1455
      End
      Begin VB.Label Lbl_Sum 
         Caption         =   "金额:"
         Height          =   255
         Left            =   480
         TabIndex        =   14
         Top             =   840
         Width           =   615
      End
      Begin VB.Label Lbl_Yuan 
         Caption         =   "元"
         Height          =   255
         Index           =   0
         Left            =   4320
         TabIndex        =   6
         Top             =   240
         Width           =   255
      End
   End
   Begin VB.ComboBox Comb_CarNum 
      Height          =   300
      Left            =   1320
      TabIndex        =   2
      Top             =   240
      Width           =   2055
   End
   Begin MSComctlLib.TabStrip TabStrip1 
      Height          =   6975
      Left            =   240
      TabIndex        =   1
      Top             =   840
      Width           =   9975
      _ExtentX        =   17595
      _ExtentY        =   12303
      MultiRow        =   -1  'True
      TabStyle        =   1
      _Version        =   393216
      BeginProperty Tabs {1EFB6598-857C-11D1-B16A-00C0F0283628} 
         NumTabs         =   3
         BeginProperty Tab1 {1EFB659A-857C-11D1-B16A-00C0F0283628} 
            Caption         =   "简易美容服务"
            ImageVarType    =   2
         EndProperty
         BeginProperty Tab2 {1EFB659A-857C-11D1-B16A-00C0F0283628} 
            Caption         =   "购买次卡"
            ImageVarType    =   2
         EndProperty
         BeginProperty Tab3 {1EFB659A-857C-11D1-B16A-00C0F0283628} 
            Caption         =   "次卡消费"
            ImageVarType    =   2
         EndProperty
      EndProperty
   End
   Begin VB.Label lbl_CarNum 
      Caption         =   "车牌:"
      Height          =   375
      Left            =   360
      TabIndex        =   0
      Top             =   240
      Width           =   735
   End
End
Attribute VB_Name = "Frm_TimesCard"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim wksMeiRong As Workspace
Dim dbMeiRong As Database
Dim rsMeiRong As Recordset
Dim intCleanCount As Integer


Private Sub Chk_Clean_Click(Index As Integer)
If Chk_Clean(Index).Value = 1 Then
  Txt_Sum.Text = CStr(CCur(Txt_Sum.Text) + CCur(Txt_CleanPrice(Index).Text))
  Else
  Txt_Sum.Text = CStr(CCur(Txt_Sum.Text) - CCur(Txt_CleanPrice(Index).Text))
End If
sngYuanLaiSum = CSng(Txt_Sum.Text)
End Sub

Private Sub Cmd_BuyCard_Click()
 
 Dim rsOpnion As Recordset
 Dim rsSelected As Recordset
 Dim i, j As Integer
 Dim intColNum As Integer
 Dim intCardId As Integer
 If Len(Comb_CarNum.Text) < 5 Then
  Call MsgBox("您还未填好写车牌号", vbOKOnly + vbInformation, STRGARAGE)
  Exit Sub
 End If
 If Grid_Selected.Rows > 2 Then
  MsgBox "一次操作只能购买一种服务!", vbInformation, STRGARAGE
  Exit Sub
 End If
 If MsgBox("为" & Comb_CarNum.Text & "购买套卡吗?", vbOKCancel + vbQuestion, STRGARAGE) = vbOK Then
  Set rsSelected = dbMeiRong.OpenRecordset("次卡消费表", dbOpenTable, dbapendonly)
  For i = 1 To Grid_Selected.Rows - 1
   j = 1
   Do Until Grid_Selected.TextMatrix(i, 0) = Grid_MeiROng.TextMatrix(j, 0)
    j = j + 1
   Loop
     With rsSelected
     .AddNew
     .Fields("车牌") = Comb_CarNum.Text
     For intColNum = 1 To Grid_MeiROng.Cols - 2
      If .Fields(intColNum + 1).Type = 3 Then '数字类型
       .Fields(intColNum + 1) = CInt(Grid_MeiROng.TextMatrix(j, intColNum))
       Else
       .Fields(intColNum + 1) = Grid_MeiROng.TextMatrix(j, intColNum)
      End If
     Next intColNum
     .Update
  End With
  Next i
  rsSelected.MoveLast
  intCardId = rsSelected.Fields(0)
  
  rsSelected.Close
    Frm_Part_SumPrice.lbl_Title = "洗车美容"
    Frm_Part_SumPrice.Lbl_Sum.Caption = "应收"
     Frm_Part_SumPrice.Label4.Caption = "元"
    Frm_Part_SumPrice.lbl_SinglePrice.Caption = "实收"
    Frm_Part_SumPrice.Txt_PartSum.Locked = True
    Frm_Part_SumPrice.Txt_PartSum.Text = Txt_CardSum.Text
    Frm_Part_SumPrice.Txt_Price.Text = Txt_CardSum.Text
    'Frm_Part_SumPrice.Txt_Price.Text = Txt_CardSum.Text
    'Frm_Part_SumPrice.Txt_Price.SelStart = 0
    'Frm_Part_SumPrice.Txt_Price.SelLength = Len(Frm_Part_SumPrice.Txt_Price.Text)

⌨️ 快捷键说明

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