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

📄 dialog.frm

📁 基于SQL2000的企业管理MRPII,包含进销存,财务,报关等组件,VB6开发,带文档说明.
💻 FRM
字号:
VERSION 5.00
Begin VB.Form Dialog 
   BorderStyle     =   3  'Fixed Dialog
   Caption         =   "查询对话框"
   ClientHeight    =   2730
   ClientLeft      =   2760
   ClientTop       =   3750
   ClientWidth     =   6540
   Icon            =   "Dialog.frx":0000
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MinButton       =   0   'False
   ScaleHeight     =   2730
   ScaleWidth      =   6540
   ShowInTaskbar   =   0   'False
   StartUpPosition =   2  '屏幕中心
   Begin VB.CommandButton C_Qk 
      Caption         =   "清空条件"
      Height          =   375
      Left            =   3450
      TabIndex        =   17
      Top             =   2220
      Width           =   945
   End
   Begin VB.Frame Frame1 
      Height          =   795
      Left            =   90
      TabIndex        =   8
      Top             =   660
      Width           =   1365
      Begin VB.OptionButton Option2 
         Caption         =   "或者"
         Height          =   195
         Left            =   60
         TabIndex        =   10
         Top             =   510
         Width           =   1035
      End
      Begin VB.OptionButton Option1 
         Caption         =   "并且"
         Height          =   225
         Left            =   60
         TabIndex        =   9
         Top             =   240
         Width           =   1065
      End
   End
   Begin VB.TextBox Text1 
      Height          =   270
      Index           =   1
      Left            =   4110
      TabIndex        =   7
      Top             =   1785
      Width           =   2325
   End
   Begin VB.ComboBox Combo2 
      Height          =   300
      Index           =   1
      ItemData        =   "Dialog.frx":0442
      Left            =   2790
      List            =   "Dialog.frx":0452
      TabIndex        =   6
      Top             =   1755
      Width           =   1245
   End
   Begin VB.ComboBox Combo1 
      Height          =   300
      Index           =   1
      ItemData        =   "Dialog.frx":0465
      Left            =   60
      List            =   "Dialog.frx":0478
      TabIndex        =   5
      Top             =   1755
      Width           =   2655
   End
   Begin VB.TextBox Text1 
      Height          =   315
      Index           =   0
      Left            =   4110
      TabIndex        =   4
      Top             =   315
      Width           =   2325
   End
   Begin VB.ComboBox Combo2 
      Height          =   300
      Index           =   0
      ItemData        =   "Dialog.frx":04A0
      Left            =   2790
      List            =   "Dialog.frx":04B0
      TabIndex        =   3
      Top             =   330
      Width           =   1245
   End
   Begin VB.ComboBox Combo1 
      Height          =   300
      Index           =   0
      ItemData        =   "Dialog.frx":04C3
      Left            =   60
      List            =   "Dialog.frx":04D6
      TabIndex        =   2
      Top             =   330
      Width           =   2655
   End
   Begin VB.CommandButton CmD_Cancel 
      Caption         =   "取消"
      Height          =   375
      Left            =   5490
      TabIndex        =   1
      Top             =   2220
      Width           =   945
   End
   Begin VB.CommandButton CmD_OK 
      Caption         =   "确定"
      Height          =   375
      Left            =   4560
      TabIndex        =   0
      Top             =   2220
      Width           =   945
   End
   Begin VB.Label Label1 
      Caption         =   "值"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9.75
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   225
      Index           =   5
      Left            =   4110
      TabIndex        =   16
      Top             =   1500
      Width           =   2265
   End
   Begin VB.Label Label1 
      Caption         =   "操作符"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9.75
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   225
      Index           =   4
      Left            =   2790
      TabIndex        =   15
      Top             =   1500
      Width           =   2265
   End
   Begin VB.Label Label1 
      Caption         =   "查询字段"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9.75
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   225
      Index           =   3
      Left            =   90
      TabIndex        =   14
      Top             =   1500
      Width           =   2265
   End
   Begin VB.Label Label1 
      Caption         =   "值"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9.75
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   285
      Index           =   2
      Left            =   4110
      TabIndex        =   13
      Top             =   60
      Width           =   2265
   End
   Begin VB.Label Label1 
      Caption         =   "操作符"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9.75
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   285
      Index           =   1
      Left            =   2790
      TabIndex        =   12
      Top             =   60
      Width           =   2265
   End
   Begin VB.Label Label1 
      Caption         =   "查询字段"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   9.75
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   285
      Index           =   0
      Left            =   90
      TabIndex        =   11
      Top             =   60
      Width           =   2265
   End
End
Attribute VB_Name = "Dialog"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False

Option Explicit
Dim Tj_A, Tj_B As String
Private Sub C_Qk_Click()
Combo1(0).Text = ""
Combo2(1).Text = ""
Combo1(1).Text = ""
Combo2(0).Text = ""
Text1(0).Text = ""
Text1(1).Text = ""
End Sub

Private Sub CmD_Cancel_Click()
Unload Me
End Sub

Private Sub CmD_OK_Click()
  'If Trim(Combo1(0).Text) <> Trim(Combo1(1).Text) And Trim(Combo1(0).Text) <> "" And Trim(Combo1(1).Text) <> "" Then
        
        If Trim(Combo1(0).Text) <> "" And Trim(Combo2(0).Text) <> "" And Trim(Text1(0).Text) <> "" Then
         Tj_A = " and " & Combo1(0).Text & Trim(Combo2(0).Text) & " '" & Trim(Str(Text1(0).Text)) & "'"
        End If
        If Trim(Combo1(0).Text) <> "" And Trim(Text1(0).Text) = "" Then
         Tj_A = " and " & Combo1(0).Text & " is null"
        End If
        If Trim(Combo1(1).Text) <> "" And Trim(Combo2(1).Text) <> "" And Trim(Text1(1).Text) <> "" Then
         Tj_B = " and " & Combo1(1).Text & Trim(Combo2(1).Text) & " '" & Trim(Str(Text1(1).Text)) & "'"
        End If
        If Trim(Combo1(1).Text) <> "" And Trim(Text1(1).Text) = "" Then
         Tj_B = " and " & Combo1(1).Text & " is null"
        End If
  Main_FrM.Ado_HZ.ConnectionString = Conn_Str
  Main_FrM.Ado_HZ.RecordSource = "select * from new_hz where not 顺序号 is null" & Tj_A & Tj_B
  Main_FrM.Ado_HZ.Refresh
   'Else
  ' Exit Sub
  'End If

Unload Me
End Sub

Private Sub Form_Load()
Me.Option1.Value = True
End Sub

⌨️ 快捷键说明

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