main_jhgl_sj.frm

来自「完整的物资管理系统源码」· FRM 代码 · 共 578 行 · 第 1/2 页

FRM
578
字号
            Type            =   0
            Format          =   ""
            HaveTrueFalseNull=   0
            FirstDayOfWeek  =   0
            FirstWeekOfYear =   0
            LCID            =   2052
            SubFormatType   =   0
         EndProperty
      EndProperty
      BeginProperty Column04 
         DataField       =   "材质"
         Caption         =   "材质"
         BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
            Type            =   0
            Format          =   ""
            HaveTrueFalseNull=   0
            FirstDayOfWeek  =   0
            FirstWeekOfYear =   0
            LCID            =   2052
            SubFormatType   =   0
         EndProperty
      EndProperty
      BeginProperty Column05 
         DataField       =   "数量"
         Caption         =   "数量"
         BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
            Type            =   0
            Format          =   ""
            HaveTrueFalseNull=   0
            FirstDayOfWeek  =   0
            FirstWeekOfYear =   0
            LCID            =   2052
            SubFormatType   =   0
         EndProperty
      EndProperty
      BeginProperty Column06 
         DataField       =   "批号或炉号"
         Caption         =   "批号或炉号"
         BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
            Type            =   0
            Format          =   ""
            HaveTrueFalseNull=   0
            FirstDayOfWeek  =   0
            FirstWeekOfYear =   0
            LCID            =   2052
            SubFormatType   =   0
         EndProperty
      EndProperty
      BeginProperty Column07 
         DataField       =   "供货单位"
         Caption         =   "供货单位"
         BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
            Type            =   0
            Format          =   ""
            HaveTrueFalseNull=   0
            FirstDayOfWeek  =   0
            FirstWeekOfYear =   0
            LCID            =   2052
            SubFormatType   =   0
         EndProperty
      EndProperty
      BeginProperty Column08 
         DataField       =   "经手人"
         Caption         =   "经手人"
         BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
            Type            =   0
            Format          =   ""
            HaveTrueFalseNull=   0
            FirstDayOfWeek  =   0
            FirstWeekOfYear =   0
            LCID            =   2052
            SubFormatType   =   0
         EndProperty
      EndProperty
      BeginProperty Column09 
         DataField       =   "仓库"
         Caption         =   "仓库"
         BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
            Type            =   0
            Format          =   ""
            HaveTrueFalseNull=   0
            FirstDayOfWeek  =   0
            FirstWeekOfYear =   0
            LCID            =   2052
            SubFormatType   =   0
         EndProperty
      EndProperty
      BeginProperty Column10 
         DataField       =   "进货票号"
         Caption         =   "进货票号"
         BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED} 
            Type            =   0
            Format          =   ""
            HaveTrueFalseNull=   0
            FirstDayOfWeek  =   0
            FirstWeekOfYear =   0
            LCID            =   2052
            SubFormatType   =   0
         EndProperty
      EndProperty
      SplitCount      =   1
      BeginProperty Split0 
         BeginProperty Column00 
            ColumnWidth     =   945.071
         EndProperty
         BeginProperty Column01 
            ColumnWidth     =   2085.166
         EndProperty
         BeginProperty Column02 
            ColumnWidth     =   2085.166
         EndProperty
         BeginProperty Column03 
            ColumnWidth     =   854.929
         EndProperty
         BeginProperty Column04 
            ColumnWidth     =   599.811
         EndProperty
         BeginProperty Column05 
            ColumnWidth     =   585.071
         EndProperty
         BeginProperty Column06 
            ColumnWidth     =   1005.165
         EndProperty
         BeginProperty Column07 
            ColumnWidth     =   1544.882
         EndProperty
         BeginProperty Column08 
            ColumnWidth     =   689.953
         EndProperty
         BeginProperty Column09 
            ColumnWidth     =   659.906
         EndProperty
         BeginProperty Column10 
            ColumnWidth     =   2204.788
         EndProperty
      EndProperty
   End
   Begin VB.Frame Frame2 
      Height          =   645
      Left            =   15
      TabIndex        =   16
      Top             =   855
      Width           =   11490
      Begin VB.CheckBox Check1 
         Height          =   270
         Index           =   1
         Left            =   120
         TabIndex        =   20
         Top             =   240
         Width           =   255
      End
      Begin MSComCtl2.DTPicker DTP1 
         Height          =   285
         Left            =   1245
         TabIndex        =   17
         Top             =   225
         Width           =   3330
         _ExtentX        =   5874
         _ExtentY        =   503
         _Version        =   393216
         Format          =   53280769
         CurrentDate     =   38679
      End
      Begin MSComCtl2.DTPicker DTP2 
         Height          =   285
         Left            =   5940
         TabIndex        =   21
         Top             =   225
         Width           =   3330
         _ExtentX        =   5874
         _ExtentY        =   503
         _Version        =   393216
         Format          =   53280769
         CurrentDate     =   38679
      End
      Begin VB.Label Label3 
         Caption         =   "结束日期"
         Height          =   210
         Left            =   4890
         TabIndex        =   22
         Top             =   300
         Width           =   765
      End
      Begin VB.Label Label2 
         Caption         =   "开始日期"
         Height          =   210
         Left            =   480
         TabIndex        =   18
         Top             =   300
         Width           =   765
      End
   End
End
Attribute VB_Name = "main_jhgl_sj"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Public selectsql As String
Private Sub Form_Load()
  Me.Caption = text
End Sub
Private Sub cmdFind_Click()
      selectsql = ""
      If text1(0) <> "" Then
        If selectsql <> "" Then
          selectsql = "物资编号 like +'" + text1(0) + "'+'%'and " & selectsql
        Else
          selectsql = "物资编号 like +'" + text1(0) + "'+'%'"
        End If
      End If
      If text1(1) <> "" Then
        If selectsql <> "" Then
          selectsql = "物资名称 like+ '" + text1(1) + "'+'%'and " & selectsql
        Else
          selectsql = "物资名称 like + '" + text1(1) + "'+'%'"
        End If
      End If
      If text1(2) <> "" Then
        If selectsql <> "" Then
          selectsql = "规格型号 like+ '" + text1(2) + "'+'%'and " & selectsql
        Else
          selectsql = "规格型号 like+ '" + text1(2) + "'+'%'"
        End If
      End If
      If text1(3) <> "" Then
        If selectsql <> "" Then
          selectsql = "计量单位 like +'" + text1(3) + "'+'%'and " & selectsql
        Else
          selectsql = "计量单位 like + '" + text1(3) + "'+'%'"
        End If
      End If
      If text1(4) <> "" Then
        If selectsql <> "" Then
          selectsql = "材质 like+ '" + text1(4) + "'+'%'and " & selectsql
        Else
          selectsql = "材质 like +'" + text1(4) + "'+'%'"
        End If
      End If
      If text1(5) <> "" Then
        If selectsql <> "" Then
          selectsql = "批号或炉号 like+ '" + text1(5) + "'+'%'and " & selectsql
        Else
          selectsql = "批号或炉号 like +'" + text1(5) + "'+'%'"
        End If
      End If
      If selectsql <> "" Then
          If Check1(0).Value = 1 Then
            Adodc1.RecordSource = "select * from tb_rk where " & selectsql & " and 检验和试验结果='无'and 状态='未送检'"
            Adodc1.Refresh
          End If
          If Check1(0).Value = 1 And Check1(1).Value = 1 Then
            Adodc1.RecordSource = "select * from tb_rk where " & selectsql & " and 进货日期 between '" + Str(DTP1.Value) + "'AND '" + Str(DTP2.Value) + "'and 检验和试验结果='无'and 状态='未送检'"
            Adodc1.Refresh
          End If
      Else
          If Check1(0).Value = 1 Or Check1(1).Value = 1 Then
            Adodc1.RecordSource = "select * from tb_rk where 检验和试验结果='无'and 状态='未送检'"
            Adodc1.Refresh
          End If
          If Check1(0).Value = 1 And Check1(1).Value = 1 Then
            Adodc1.RecordSource = "select * from tb_rk where 进货日期 between '" + Str(DTP1.Value) + "'AND '" + Str(DTP2.Value) + "'and 检验和试验结果='无'and 状态='未送检'"
            Adodc1.Refresh
          End If
      End If
      If Check1(1).Value = 1 Then
         Adodc1.RecordSource = "select * from tb_rk where 进货日期 between '" + Str(DTP1.Value) + "'AND '" + Str(DTP2.Value) + "'and 检验和试验结果='无'and 状态='未送检'"
         Adodc1.Refresh
      End If
End Sub
Private Sub cmdSend_Click()
  cmdFind_Click
  If Adodc1.Recordset.RecordCount > 0 Then
    '指定表格内容
     Adodc1.Recordset.MoveFirst
     Do Until Adodc1.Recordset.EOF
          cnn.Execute ("update tb_rk set 状态='送检',送检时间='" + Str(Date) + "'")
          Adodc1.Recordset.MoveNext
     Loop
  Else
    MsgBox "没有送检物资!", , "提示窗口"
  End If
End Sub
Private Sub cmdEnd_Click()
  Unload Me
End Sub


⌨️ 快捷键说明

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