📄 frm选择产品图号.frm
字号:
VERSION 5.00
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
Object = "{D959C709-8613-11D1-9840-002078110E7D}#1.0#0"; "as97Popup.ocx"
Begin VB.Form Frm选择产品图号
BorderStyle = 3 'Fixed Dialog
Caption = "选择物资编号"
ClientHeight = 7140
ClientLeft = 2760
ClientTop = 3750
ClientWidth = 7650
Icon = "Frm选择产品图号.frx":0000
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 7140
ScaleWidth = 7650
StartUpPosition = 1 '所有者中心
Begin VB.TextBox Text6
Alignment = 2 'Center
BeginProperty Font
Name = "宋体"
Size = 12
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 2520
MaxLength = 10
TabIndex = 0
Text = "图号"
Top = 120
Width = 2055
End
Begin VB.TextBox Text7
Alignment = 2 'Center
BeginProperty Font
Name = "宋体"
Size = 12
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 2520
MaxLength = 15
TabIndex = 1
Text = "品名"
Top = 600
Width = 2055
End
Begin VB.CommandButton Command6
Caption = "查询"
Height = 375
Left = 4800
TabIndex = 2
Top = 360
Width = 855
End
Begin VB.CommandButton Command1
Caption = "退出"
Height = 495
Left = 6000
TabIndex = 4
Top = 300
Width = 975
End
Begin MSComctlLib.ListView lstContracts
Height = 5895
Left = 120
TabIndex = 3
Top = 1200
Width = 7335
_ExtentX = 12938
_ExtentY = 10398
View = 3
LabelEdit = 1
LabelWrap = -1 'True
HideSelection = 0 'False
FullRowSelect = -1 'True
GridLines = -1 'True
_Version = 393217
ForeColor = -2147483640
BackColor = -2147483643
BorderStyle = 1
Appearance = 1
NumItems = 0
End
Begin as97Popup.asPopup asPopup1
Height = 735
Left = 240
Top = 240
Width = 855
_ExtentX = 1508
_ExtentY = 1296
CustomPicture = "Frm选择产品图号.frx":0CCA
Caption = "选中"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Layout = 3
ScaleWidth = 57
ScaleMode = 0
ScaleHeight = 49
BackStyle = 0
End
Begin as97Popup.asPopup asPopup
DragIcon = "Frm选择产品图号.frx":15A4
Height = 735
Left = 1320
Top = 240
Width = 735
_ExtentX = 1296
_ExtentY = 1296
CustomPicture = "Frm选择产品图号.frx":1E6E
Caption = "添加"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Layout = 3
ScaleWidth = 49
ScaleMode = 0
ScaleHeight = 49
BackStyle = 0
End
Begin VB.Line Line1
X1 = 120
X2 = 7440
Y1 = 1080
Y2 = 1080
End
End
Attribute VB_Name = "Frm选择产品图号"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Dim LConRs As ADODB.Recordset
Dim TxtSql As String
Dim SqlSctmp As String
Private Sub DoList()
If Trim(Text6.Text) <> "" And Trim(Text7.Text) = "" Then
SqlSctmp = "select * from Bs_产品图号 where 图号 LIKE '%" & Trim(Text6.Text) & "%' order by 图号,品名"
End If
If Trim(Text6.Text) = "" And Trim(Text7.Text) <> "" Then
SqlSctmp = "select * from Bs_产品图号 where 品名 LIKE '%" & Trim(Text7.Text) & "%' order by 图号,品名"
End If
SqlSctmp = "select * from Bs_产品图号 where 图号 LIKE '%" & Trim(Text6.Text) & "%' and 品名 LIKE '%" & Trim(Text7.Text) & "%' order by 图号,品名"
Dim ItmX As ListItem
lstContracts.ColumnHeaders.Clear
lstContracts.ColumnHeaders.Add , , "ID", 900
lstContracts.ColumnHeaders.Add , , "图号", 1200
lstContracts.ColumnHeaders.Add , , "品名", 1200
lstContracts.ColumnHeaders.Add , , "规格", 1500
lstContracts.ColumnHeaders.Add , , "硝材", 1200
lstContracts.ColumnHeaders.Add , , "创建者", 900
Set LConRs = New ADODB.Recordset
LConRs.Open SqlSctmp, Cw_DataEnvi.DataConnect, adOpenStatic, adLockReadOnly, adCmdText
If Not LConRs.BOF Then LConRs.MoveFirst
lstContracts.ListItems.Clear
Do While Not LConRs.EOF
Set ItmX = lstContracts.ListItems.Add(, , LConRs!Id)
ItmX.SubItems(1) = LConRs!图号
ItmX.SubItems(2) = LConRs!品名
ItmX.SubItems(3) = LConRs!规格
ItmX.SubItems(4) = LConRs!硝材
ItmX.SubItems(5) = LConRs!创建者
LConRs.MoveNext
Loop
If Not LConRs.EOF Then LConRs.MoveFirst
lstContracts.Refresh
End Sub
Private Sub asPopup_Click(Cancel As Boolean)
If Not Security_Log("XT_jcsj_CPTH", Xtczybm, 1, True) Then
MsgBox "您没有相应的权限!", vbCritical, "请咨询管理员:"
Exit Sub
End If
FrmCpwh.Show 1
DoList
End Sub
'Private Sub asPopup1_Click(Cancel As Boolean)
'On Error Resume Next
'
' If Not lstContracts.ListItems.Count < 1 Then
' Dim BH As String
' BH = Trim(lstContracts.SelectedItem.Text)
' If SecWz = 1 Then
' FrmLldj01.WZlist (BH)
' ElseIf SecWz = 2 Then
' FrmLldj02.WZlist (BH)
' ElseIf SecWz = 3 Then
' Frmzjdj01.WZlist (BH)
' ElseIf SecWz = 4 Then
' Frmzjdj02.WZlist (BH)
' End If
'
' End If
'
' Command1_Click
'End Sub
Private Sub Command1_Click()
Unload Me
End Sub
Private Sub Command6_Click()
DoList
End Sub
Private Sub Form_Load()
DoList
End Sub
Private Sub lstContracts_DblClick()
' asPopup1_Click (True)
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -