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

📄 frmothers2.frm

📁 Call centeer gestion de usuarios todo ello gratis y bajo windows
💻 FRM
📖 第 1 页 / 共 2 页
字号:
         BeginProperty Buttons {66833FE8-8583-11D1-B16A-00C0F0283628} 
            NumButtons      =   5
            BeginProperty Button1 {66833FEA-8583-11D1-B16A-00C0F0283628} 
               Caption         =   "Add"
               Key             =   "Add"
               ImageIndex      =   1
            EndProperty
            BeginProperty Button2 {66833FEA-8583-11D1-B16A-00C0F0283628} 
               Style           =   3
            EndProperty
            BeginProperty Button3 {66833FEA-8583-11D1-B16A-00C0F0283628} 
               Caption         =   "Edit"
               Key             =   "Edit"
               ImageIndex      =   2
            EndProperty
            BeginProperty Button4 {66833FEA-8583-11D1-B16A-00C0F0283628} 
               Style           =   3
            EndProperty
            BeginProperty Button5 {66833FEA-8583-11D1-B16A-00C0F0283628} 
               Caption         =   "Trash"
               Key             =   "Trash"
               ImageIndex      =   3
            EndProperty
         EndProperty
      End
      Begin MSComctlLib.ListView lvP 
         Height          =   4095
         HelpContextID   =   7
         Left            =   -74880
         TabIndex        =   6
         Top             =   420
         WhatsThisHelpID =   7
         Width           =   9135
         _ExtentX        =   16113
         _ExtentY        =   7223
         View            =   3
         LabelWrap       =   -1  'True
         HideSelection   =   -1  'True
         FullRowSelect   =   -1  'True
         GridLines       =   -1  'True
         HotTracking     =   -1  'True
         HoverSelection  =   -1  'True
         TextBackground  =   -1  'True
         _Version        =   393217
         SmallIcons      =   "ImageList1"
         ForeColor       =   -2147483640
         BackColor       =   16761024
         BorderStyle     =   1
         Appearance      =   1
         BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
            Name            =   "Century Gothic"
            Size            =   9
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         NumItems        =   3
         BeginProperty ColumnHeader(1) {BDD1F052-858B-11D1-B16A-00C0F0283628} 
            Text            =   "Pool No."
            Object.Width           =   1764
         EndProperty
         BeginProperty ColumnHeader(2) {BDD1F052-858B-11D1-B16A-00C0F0283628} 
            SubItemIndex    =   1
            Text            =   "Description"
            Object.Width           =   5116
         EndProperty
         BeginProperty ColumnHeader(3) {BDD1F052-858B-11D1-B16A-00C0F0283628} 
            SubItemIndex    =   2
            Text            =   "Price"
            Object.Width           =   1676
         EndProperty
      End
      Begin MSComctlLib.Toolbar Toolbar3 
         Height          =   570
         Left            =   -74880
         TabIndex        =   7
         Top             =   4620
         Width           =   3735
         _ExtentX        =   6588
         _ExtentY        =   1005
         ButtonWidth     =   1984
         ButtonHeight    =   1005
         Appearance      =   1
         Style           =   1
         TextAlignment   =   1
         ImageList       =   "ImageList2"
         _Version        =   393216
         BeginProperty Buttons {66833FE8-8583-11D1-B16A-00C0F0283628} 
            NumButtons      =   5
            BeginProperty Button1 {66833FEA-8583-11D1-B16A-00C0F0283628} 
               Caption         =   "Add"
               Key             =   "Add"
               ImageIndex      =   1
            EndProperty
            BeginProperty Button2 {66833FEA-8583-11D1-B16A-00C0F0283628} 
               Style           =   3
            EndProperty
            BeginProperty Button3 {66833FEA-8583-11D1-B16A-00C0F0283628} 
               Caption         =   "Edit"
               Key             =   "Edit"
               ImageIndex      =   2
            EndProperty
            BeginProperty Button4 {66833FEA-8583-11D1-B16A-00C0F0283628} 
               Style           =   3
            EndProperty
            BeginProperty Button5 {66833FEA-8583-11D1-B16A-00C0F0283628} 
               Caption         =   "Trash"
               Key             =   "Trash"
               ImageIndex      =   3
            EndProperty
         EndProperty
      End
   End
End
Attribute VB_Name = "frmOthers2"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Public ron As String

Private Sub Command1_Click()
Unload Me
End Sub


Private Sub Command2_Click()
If Command2.Caption = "Switch to ROP mode" Then
   Command2.Caption = "Switch to normal mode"
   fillrop
   lvD.ForeColor = vbRed
ElseIf Command2.Caption = "Switch to normal mode" Then
   lvD.ForeColor = vbBlack
   Command2.Caption = "Switch to ROP mode"
   fillDrinks
End If

End Sub

Private Sub Form_Load()
check_RS
rs.Open "select * from swimmingpool order by swimmingpool_no asc", Cnn
fillPool
'======
check_RS1
rs1.Open "select * from food order by food_no asc", Cnn
fillFood
'======
check_RS2
rs2.Open "select * from liquor order by liquor_no asc", Cnn
fillDrinks
'======
End Sub
Public Sub fillPool()
On Error GoTo s
check_RS
rs.Open "select * from swimmingpool order by swimmingpool_no asc", Cnn
Dim x As Integer
    lvP.ListItems.Clear
While Not rs.EOF
  Set lst = lvP.ListItems.Add(, , rs(0), , 1)
For x = 1 To 2
   lst.SubItems(x) = rs(x)
Next x
rs.MoveNext
Wend
s:
End Sub
Public Sub fillrop()
check_RS2
rs2.Open "select * from liquor where ROP >=  quantity order by liquor_no", Cnn
'check_RS2
'rs2.Open "select * from drinks order by drinks_no asc", Cnn
Dim x As Integer
    lvD.ListItems.Clear
While Not rs2.EOF
  Set lst = lvD.ListItems.Add(, , rs2(0), , 1)
For x = 1 To 6
   lst.SubItems(x) = rs2(x)
Next x
rs2.MoveNext
Wend
End Sub

Public Sub fillDrinks()
'check_RS2
'rs2.Open "select * from drinks where ROP >=  quantity order by drinks_no", Cnn
check_RS2
rs2.Open "select * from liquor order by liquor_no asc", Cnn
Dim x As Integer
    lvD.ListItems.Clear
While Not rs2.EOF
  Set lst = lvD.ListItems.Add(, , rs2(0), , 1)
For x = 1 To 6
   lst.SubItems(x) = rs2(x)
Next x
rs2.MoveNext
Wend
End Sub
Public Sub fillFood()
check_RS1
rs1.Open "select * from food order by food_no asc", Cnn
Dim x As Integer
    lvF.ListItems.Clear
While Not rs1.EOF
  Set lst = lvF.ListItems.Add(, , rs1(0), , 1)
For x = 1 To 2
   lst.SubItems(x) = rs1(x)
Next x
rs1.MoveNext
Wend
End Sub
Private Sub lvD_DblClick()
'On Error GoTo m
Dim x As Integer
ron = "edit"
LiquorData.data(0) = lvD.SelectedItem.Text
LiquorData.data(0).Locked = True
For x = 1 To 6
LiquorData.data(x) = lvD.SelectedItem.SubItems(x)
Next x
LiquorData.Show 1
'm:
End Sub
Private Sub lvF_DblClick()
On Error GoTo m
Dim x As Integer
ron = "edit"
FoodData.data(0) = lvF.SelectedItem.Text
FoodData.data(0).Locked = True
For x = 1 To 2
FoodData.data(x) = lvF.SelectedItem.SubItems(x)
Next x
'Load FoodData
FoodData.Show 1
m:

End Sub

Private Sub lvP_DblClick()
Dim x As Integer
ron = "edit"
PoolData.data(0) = lvP.SelectedItem.Text
PoolData.data(0).Locked = True
For x = 1 To 2
PoolData.data(x) = lvP.SelectedItem.SubItems(x)
Next x
Load PoolData
PoolData.Show 1
'm:
End Sub


Private Sub Toolbar1_ButtonClick(ByVal Button As MSComctlLib.Button)
Select Case Button.key
'=======
Case "Add"
ron = "add"
'Load FoodData
FoodData.Show 1
'=======
Case "Edit"
Call lvF_DblClick
'=======
Case "Trash"
On Error GoTo m
If MsgBox("Are you sure do you want to delete food " & lvF.SelectedItem.SubItems(1), vbYesNo) = vbYes Then
Cnn.Execute "delete from food where food_no = " & lvF.SelectedItem.Text
rs.Requery 1
fillFood
End If
m:
'=======
End Select

End Sub

Private Sub Toolbar2_ButtonClick(ByVal Button As MSComctlLib.Button)
Select Case Button.key
'=======
Case "Add"
ron = "add"
'Load FoodData
LiquorData.Show 1
'=======
Case "Edit"
Call lvD_DblClick
'=======
Case "Trash"
On Error GoTo m
If MsgBox("Are you sure do you want to delete liquor " & lvD.SelectedItem.SubItems(1), vbYesNo) = vbYes Then
Cnn.Execute "delete from liquor where liquor_no = " & lvD.SelectedItem.Text
rs.Requery 1
fillDrinks
End If
m:
'=======
End Select
End Sub
Private Sub Toolbar3_ButtonClick(ByVal Button As MSComctlLib.Button)
Select Case Button.key
'=======
Case "Add"
ron = "add"
'Load FoodData
PoolData.Show 1
'=======
Case "Edit"
Call lvP_DblClick
'=======
Case "Trash"
On Error GoTo m
If MsgBox("Are you sure do you want to delete pool " & lvP.SelectedItem.SubItems(1), vbYesNo) = vbYes Then
Cnn.Execute "delete from swimmingpool where swimmingpool_no = " & lvP.SelectedItem.Text
rs.Requery 1
fillPool
End If
m:
'=======
End Select

End Sub

⌨️ 快捷键说明

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