📄 高级联系人查找.frm
字号:
VERSION 5.00
Object = "{E95A2510-F3D1-416D-823B-4F840FE98091}#3.0#0"; "Command.ocx"
Begin VB.Form Form9
Caption = "高级查找----联系人查找"
ClientHeight = 2640
ClientLeft = 60
ClientTop = 390
ClientWidth = 6360
LinkTopic = "Form9"
LockControls = -1 'True
MaxButton = 0 'False
MDIChild = -1 'True
ScaleHeight = 2640
ScaleWidth = 6360
Begin CSCommand.Command Command1
Height = 390
Left = 4710
TabIndex = 13
Top = 2130
Width = 1500
_ExtentX = 2646
_ExtentY = 688
IconAlign = 0
Icon = "高级联系人查找.frx":0000
Caption = "开始查询 &S"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
End
Begin VB.Frame Frame1
Caption = "设定查询的条件"
Height = 1845
Left = 135
TabIndex = 14
Top = 165
Width = 6075
Begin VB.ComboBox Combo4
Height = 300
ItemData = "高级联系人查找.frx":001C
Left = 1320
List = "高级联系人查找.frx":004D
Style = 2 'Dropdown List
TabIndex = 10
Top = 1395
Width = 1935
End
Begin VB.ComboBox Combo3
Height = 300
ItemData = "高级联系人查找.frx":00CF
Left = 1320
List = "高级联系人查找.frx":0100
Style = 2 'Dropdown List
TabIndex = 7
Top = 1025
Width = 1935
End
Begin VB.ComboBox Combo2
Height = 300
ItemData = "高级联系人查找.frx":0182
Left = 1320
List = "高级联系人查找.frx":01B3
Style = 2 'Dropdown List
TabIndex = 4
Top = 655
Width = 1935
End
Begin VB.ComboBox Combo1
Height = 300
ItemData = "高级联系人查找.frx":0235
Left = 1320
List = "高级联系人查找.frx":0266
Style = 2 'Dropdown List
TabIndex = 1
Top = 285
Width = 1935
End
Begin VB.CheckBox Check1
Caption = "第一条件:"
Height = 300
Left = 165
TabIndex = 0
Top = 300
Value = 1 'Checked
Width = 1200
End
Begin VB.CheckBox Check2
Caption = "第二条件:"
Height = 300
Left = 165
TabIndex = 3
Top = 675
Width = 1260
End
Begin VB.CheckBox Check3
Caption = "第三条件:"
Height = 300
Left = 165
TabIndex = 6
Top = 1035
Width = 1260
End
Begin VB.CheckBox Check4
Caption = "第四条件:"
Height = 300
Left = 165
TabIndex = 9
Top = 1410
Width = 1260
End
Begin VB.TextBox Text2
Height = 285
Left = 3765
TabIndex = 2
Top = 270
Width = 2205
End
Begin VB.TextBox Text3
Height = 285
Left = 3765
TabIndex = 5
Top = 645
Width = 2205
End
Begin VB.TextBox Text4
Height = 285
Left = 3765
TabIndex = 8
Top = 1020
Width = 2205
End
Begin VB.TextBox Text5
Height = 285
Left = 3765
TabIndex = 11
Top = 1395
Width = 2205
End
Begin VB.Label Label1
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "包含"
Height = 180
Left = 3345
TabIndex = 18
Top = 315
Width = 360
End
Begin VB.Label Label2
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "包含"
Height = 180
Left = 3345
TabIndex = 17
Top = 690
Width = 360
End
Begin VB.Label Label3
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "包含"
Height = 180
Left = 3345
TabIndex = 16
Top = 1065
Width = 360
End
Begin VB.Label Label4
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "包含"
Height = 180
Left = 3345
TabIndex = 15
Top = 1440
Width = 360
End
End
Begin VB.CheckBox Check5
Caption = "查询完毕关闭本窗体"
Height = 225
Left = 225
TabIndex = 12
Top = 2130
Width = 2040
End
End
Attribute VB_Name = "Form9"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
'****************************************************************************
'人人为我,我为人人
'枕善居收藏整理
'发布日期:2007/12/24
'描 述:商务名片及客户资料管理系统 Ver 1.73
'网 站:http://www.Mndsoft.com/ (VB6源码博客)
'网 站:http://www.VbDnet.com/ (VB.NET源码博客,主要基于.NET2005)
'e-mail :Mndsoft@163.com
'e-mail :Mndsoft@126.com
'OICQ :88382850
' 如果您有新的好的代码别忘记给枕善居哦!
'****************************************************************************
Option Explicit
Private Sub Command1_Click()
Dim FirstLike As Boolean
Dim sqlstr As String
sqlstr = "select * from ren where "
If Check1.Value = 1 And Trim(Text2.Text) <> "" Then
sqlstr = sqlstr & " " & Combo1.Text & " " & "like '*" & Trim(Text2.Text) & "*' "
FirstLike = True
End If
If Check2.Value = 1 And Trim(Text3.Text) <> "" Then
If FirstLike = True Then
sqlstr = sqlstr & " And "
Else
FirstLike = True
End If
sqlstr = sqlstr & Combo2.Text & " " & "like '*" & Trim(Text3.Text) & "*' "
End If
If Check3.Value = 1 And Trim(Text4.Text) <> "" Then
If FirstLike = True Then
sqlstr = sqlstr & " And "
Else
FirstLike = True
End If
sqlstr = sqlstr & Combo3.Text & " " & "like '*" & Trim(Text4.Text) & "*' "
End If
If Check4.Value = 1 And Trim(Text5.Text) <> "" Then
If FirstLike = True Then
sqlstr = sqlstr & " And "
Else
FirstLike = True
End If
sqlstr = sqlstr & Combo4.Text & " " & "like '*" & Trim(Text5.Text) & "*' "
End If
sqlstr = sqlstr & " order by id desc "
If FirstLike = True Then
ShowAllRen (sqlstr)
End If
If Check5.Value = 1 Then
Unload Me
End If
End Sub
Private Sub Form_Load()
Me.Icon = MDIForm1.Icon
Me.BackColor = FormBackColor: Me.Frame1.BackColor = Me.BackColor
form8show = True
Me.Height = 3150
Me.Width = 6375
Me.Check1.BackColor = Me.BackColor
Me.Check2.BackColor = Me.BackColor
Me.Check3.BackColor = Me.BackColor
Me.Check4.BackColor = Me.BackColor
Me.Check5.BackColor = Me.BackColor
End Sub
Private Sub Form_Resize()
On Error GoTo reerror
Me.Height = 3150
Me.Width = 6375
reerror:
End Sub
Private Sub Form_Unload(Cancel As Integer)
form8show = False
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -