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

📄 cxdd.frm

📁 关于图书销售管理
💻 FRM
📖 第 1 页 / 共 2 页
字号:
            ItemData        =   "cxdd.frx":0442
            Left            =   600
            List            =   "cxdd.frx":044F
            TabIndex        =   4
            Text            =   "等于"
            Top             =   360
            Width           =   1455
         End
      End
      Begin VB.CommandButton Command1 
         Caption         =   "确定(&O)"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   12
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   495
         Left            =   2160
         TabIndex        =   2
         Top             =   2520
         Width           =   1095
      End
      Begin VB.CommandButton Command2 
         Caption         =   "取消(&C)"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   12
            Charset         =   134
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   495
         Left            =   3480
         TabIndex        =   1
         Top             =   2520
         Width           =   1095
      End
   End
End
Attribute VB_Name = "cxdd"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Public a As Integer

Private Sub Command1_Click()
   Dim oIndex As Integer
   If Option1(0).Value = True Then
       oIndex = 0
      
   End If
   If Option1(1).Value = True Then
      oIndex = 1
  
   End If
   If Option1(2).Value = True Then
       oIndex = 2
      
   End If
   If Option1(3).Value = True Then oIndex = 3
   If Option2.Value = True Then oIndex = 4
   If Option3.Value = True Then oIndex = 5
   If Option4.Value = True Then oIndex = 6
   
  '查找职员
    Select Case oIndex
          Case 0
              dhdcl1.Data2.RecordSource = "select * from spdhd where " & "ddbh" & " = '" & Trim(Text1.Text) & "'"
              dhdcl1.Adodc1.RecordSource = "select * from dhdsp where " & "ddbh" & " = '" & Trim(Text1.Text) & "'"
          Case 1
              ' dhdcl1.Data2.RecordSource = "select * from spdhd where " & "spbh" & " = '" & Trim(Text1.Text) & "'"
                dhdcl1.Adodc1.RecordSource = "select  spbh,ddbh,gg,dj,sl,ysje,zk,bz from dhdsp where " & "spbh" & " = '" & Trim(Text1.Text) & "'"
                dhdcl1.Adodc1.Refresh
                 
          Case 2
               dhdcl1.Data1.Recordset.FindFirst "spmc='" & Trim(Text1.Text) & "'"
               bh = dhdcl1.Data1.Recordset("spbh")
               dhdcl1.Adodc1.RecordSource = "select * from dhdsp where " & "spbh" & " = '" & bh & "'"
          Case 3
                  If Combo1.Text = "等于" Then
                        dhdcl1.Data2.RecordSource = "select * from spdhd where " & "lrrq " & " =  #" & Format(CDate(Trim(Text1.Text)), "mmm d yyyy") & "#"
                  End If
                  If Combo1.Text = "大于" Then
                       dhdcl1.Data2.RecordSource = "select * from spdhd where " & "lrrq" & "  >   #" & Format(CDate(Trim(Text1.Text)), "mmm d yyyy") & "#"
                  End If
                If Combo1.Text = "小于" Then
                       dhdcl1.Data2.RecordSource = "select * from spdhd where " & "lrrq" & "  <    #" & Format(CDate(Text1.Text), "mmm d yyyy") & "#"
                End If
          Case 4
                  If Combo1.Text = "等于" Then
                        dhdcl1.Data2.RecordSource = "select * from spdhd where " & "dhrq " & " =  #" & Format(CDate(Trim(Text1.Text)), "mmm d yyyy") & "#"
                  End If
                  If Combo1.Text = "大于" Then
                       dhdcl1.Data2.RecordSource = "select * from spdhd where " & "dhrq" & "  >   #" & Format(CDate(Trim(Text1.Text)), "mmm d yyyy") & "#"
                  End If
                  If Combo1.Text = "小于" Then
                       dhdcl1.Data2.RecordSource = "select * from spdhd where " & "dhrq" & "  <    #" & Format(CDate(Text1.Text), "mmm d yyyy") & "#"
                  End If
          Case 5
               dhdcl1.Data2.RecordSource = "select * from spdhd where " & "jsr" & " = '" & Trim(Text1.Text) & "'"
          Case 6
                 If Combo1.Text = "等于" Then
                        dhdcl1.Data2.RecordSource = "select * from spdhd where " & "ljje " & " =  " & Val(Text1.Text)
                  End If
                  If Combo1.Text = "大于" Then
                       dhdcl1.Data2.RecordSource = "select * from spdhd where " & "ljje" & "  >   " & Val(Text1.Text)
                  End If
                  If Combo1.Text = "小于" Then
                       dhdcl1.Data2.RecordSource = "select * from spdhd where " & "ljje" & "  <    " & Val(Text1.Text)
                  End If
                  dhdcl1.Adodc1.RecordSource = "select * from dhdsp where " & "ddbh" & " = '" & (Text1.Text) & "'"
    
    End Select
'
       'dhdcl1.Show
         

    dhdcl1.Data2.Refresh
   If dhdcl1.Data2.Recordset.BOF = True Then
               MsgBox "没有找到符合条件的记录。", vbInformation, "提示"
              dhdcl1.Data2.RecordSource = "select * from spdhd "
              dhdcl1.Adodc1.RecordSource = "select spbh,dhdbh,gg,dj,sl,yfje,zk,bz from dhdsp "
              dhdcl1.Data2.Refresh
              dhdcl1.Adodc1.Refresh
             dhdcl1.Text1.Text = dhdcl1.Data2.Recordset("ddbh")
                dhdcl1.Text2.Text = dhdcl1.Data2.Recordset("lrrq")
                dhdcl1.Text3.Text = dhdcl1.Data2.Recordset("dhrq")
                'Text4.Text = Data2.Recordset("ghs")
                'dhdcl1.Text5.Text = dhdcl1.Data2.Recordset("jsr")
                dhdcl1.Text6.Text = dhdcl1.Data2.Recordset("ljje")
                dhdcl1.Text7.Text = dhdcl1.Data2.Recordset("dingjin")
                'Text7.Text = Data2.Recordset("zk")
                On Error Resume Next
                dhdcl1.Data1.Recordset.FindFirst "spbh='" & dhdcl1.Adodc1.Recordset("spbh") & "'"
                ''Text8.Text = Data1.Recordset("spmc")
                dhdcl1.Text4.Text = dhdcl1.Data1.Recordset("ghs")
                'Text14.Text = Data1.Recordset("dw")
                ' Text7.Text = Data1.Recordset("ys")
                dhdcl1.Adodc1.Recordset.Filter = "  dhdbh =  '" & dhdcl1.Text1.Text & "'"
                dhdcl1.Show
              
              'Call dhdcl1_formactivate
              Unload Me
                
         Else
'         If oIndex = 1 Then
'                     dhdcl1.Adodc1.Recordset.MoveLast
'                     l = dhdcl1.Adodc1.Recordset.RecordCount
'                     dhdcl1.StatusBar1.Panels(3).Text = "共找到符合条件的记录 " & l & " 条"
'                      dhdcl1.Show
'                Else
                    dhdcl1.Data2.Recordset.MoveFirst
                     dhdcl1.Data2.Recordset.MoveLast
                     l = dhdcl1.Data2.Recordset.RecordCount
                      dhdcl1.StatusBar1.Panels(3).Text = "共找到符合条件的订单 " & l & " 张"
                    dhdcl1.Show
               
    End If
'spdhd1.Data2.Recordset.MoveFirst
dhdcl1.DataGrid1.Columns(0).Width = 1000
dhdcl1.DataGrid1.Columns(1).Width = 1000
dhdcl1.DataGrid1.Columns(2).Width = 1500
dhdcl1.DataGrid1.Columns(3).Width = 1000
dhdcl1.DataGrid1.Columns(4).Width = 1000
dhdcl1.DataGrid1.Columns(5).Width = 1000
dhdcl1.DataGrid1.Columns(6).Width = 1000
dhdcl1.DataGrid1.Columns(7).Width = 1000

dhdcl1.DataGrid1.Columns(0).Caption = " 商品编号"
dhdcl1.DataGrid1.Columns(2).Caption = "  规格"
'dhdcl1.DataGrid1.Columns(3).Caption = "  颜色"
dhdcl1.DataGrid1.Columns(3).Caption = "  单价"
dhdcl1.DataGrid1.Columns(4).Caption = "  数量"
dhdcl1.DataGrid1.Columns(5).Caption = "  应付金额"
dhdcl1.DataGrid1.Columns(6).Caption = "  折扣"
dhdcl1.DataGrid1.Columns(7).Caption = "  备注"

Unload Me
'Combo1.Enabled = True
End Sub

Private Sub Command2_Click()
dhdcl1.Show
Unload Me
End Sub

Private Sub Option1_Click(Index As Integer)
If Option1(0).Value = True Then
  Text1.Text = ""
  Combo1.Enabled = False
End If
If Option1(1).Value = True Then
    Text1.Text = ""
    Combo1.Enabled = False
End If
If Option1(2).Value = True Then
    Text1.Text = ""
    Combo1.Enabled = False
End If
If Option1(3).Value = True Then
   Text1.Text = "##-##-##"
   Combo1.Enabled = True
End If


End Sub

Private Sub Option2_Click()
If Option2.Value = True Then
   Text1.Text = "##-##-##"
   Combo1.Enabled = True
End If
End Sub

Private Sub Option3_Click()
If Option3.Value = True Then
   Text1.Text = ""
   Combo1.Enabled = False
End If
End Sub

Private Sub Option4_Click()
If Option4.Value = True Then
   Text1.Text = ""
  Combo1.Enabled = True
End If
End Sub

⌨️ 快捷键说明

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