📄 frmmain.frm
字号:
Height = 345
Left = 2820
Options = 0
ReadOnly = 0 'False
RecordsetType = 1 'Dynaset
RecordSource = ""
Top = 7110
Visible = 0 'False
Width = 1140
End
Begin VB.Data Data2
Caption = "Data2"
Connect = "Access"
DatabaseName = ""
DefaultCursorType= 0 '缺省游标
DefaultType = 2 '使用 ODBC
Exclusive = 0 'False
Height = 345
Left = 1650
Options = 0
ReadOnly = 0 'False
RecordsetType = 1 'Dynaset
RecordSource = ""
Top = 7140
Visible = 0 'False
Width = 1140
End
Begin VB.Data Data1
Caption = "Data1"
Connect = "Access"
DatabaseName = ""
DefaultCursorType= 0 '缺省游标
DefaultType = 2 '使用 ODBC
Exclusive = 0 'False
Height = 345
Left = 450
Options = 0
ReadOnly = 0 'False
RecordsetType = 1 'Dynaset
RecordSource = ""
Top = 7140
Visible = 0 'False
Width = 1140
End
Begin MSComDlg.CommonDialog dlgCommonDialog
Left = 11220
Top = 30
_ExtentX = 847
_ExtentY = 847
_Version = 393216
End
Begin MSComctlLib.StatusBar sbStatusBar
Align = 2 'Align Bottom
Height = 270
Left = 0
TabIndex = 0
Top = 4560
Width = 6810
_ExtentX = 12012
_ExtentY = 476
_Version = 393216
BeginProperty Panels {8E3867A5-8586-11D1-B16A-00C0F0283628}
NumPanels = 3
BeginProperty Panel1 {8E3867AB-8586-11D1-B16A-00C0F0283628}
AutoSize = 1
Object.Width = 6324
Text = "状态"
TextSave = "状态"
EndProperty
BeginProperty Panel2 {8E3867AB-8586-11D1-B16A-00C0F0283628}
Style = 6
AutoSize = 2
TextSave = "99-7-6"
EndProperty
BeginProperty Panel3 {8E3867AB-8586-11D1-B16A-00C0F0283628}
Style = 5
AutoSize = 2
TextSave = "21:36"
EndProperty
EndProperty
End
Begin VB.Image Image1
Height = 2955
Left = 6120
Stretch = -1 'True
Top = 510
Width = 4185
End
Begin ActiveBarLibraryCtl.ActiveBar ActiveBar1
Left = 10560
Top = 30
_ExtentX = 847
_ExtentY = 847
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "Arial"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Bands = "frmMain.frx":1691
End
Begin VB.Label Label1
Caption = "备注"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 195
Index = 7
Left = 90
TabIndex = 17
Top = 1350
Width = 435
End
Begin VB.Label Label1
Caption = "报价方式"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 195
Index = 6
Left = 3210
TabIndex = 16
Top = 960
Width = 855
End
Begin VB.Label Label1
Caption = "单价"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 195
Index = 5
Left = 1350
TabIndex = 15
Top = 990
Width = 435
End
Begin VB.Label Label1
Caption = "单位"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 195
Index = 4
Left = 60
TabIndex = 14
Top = 960
Width = 465
End
Begin VB.Label Label1
Caption = "名称"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 195
Index = 3
Left = 60
TabIndex = 13
Top = 600
Width = 435
End
Begin VB.Label Label1
Caption = "图象文件名"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 255
Index = 2
Left = 4980
TabIndex = 12
Top = 150
Width = 1095
End
Begin VB.Label Label1
Caption = "类别"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 195
Index = 1
Left = 2520
TabIndex = 11
Top = 150
Width = 465
End
Begin VB.Label Label1
Caption = "型体"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 255
Index = 0
Left = 60
TabIndex = 9
Top = 120
Width = 465
End
End
Attribute VB_Name = "frmMain"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub findyp()
Frm查询.Show 1
If hxffh = True Then
If hxffhz <> "" Then
Me.Data1.RecordSource = "SELECT * FROM 样品资料 where [型体] LIKE '" & Trim(hxffhz) & "*'"
Else
Me.Data1.RecordSource = "SELECT * FROM 样品资料"
End If
Me.Data1.Refresh
If Data1.Recordset.RecordCount = 0 Then
HXFYN = MsgBox("无需要查询的样品!", 48, "信息提示")
End If
Call rest
End If
If Data1.Recordset("图形文件名") > 0 Then
If filef(Trim(Data1.Recordset("图形文件名"))) Then
End If
End If
End Sub
Private Sub DELEYP()
HXFYN = MsgBox("是否删除样品,删除该样品将删除对应的所有报价记录!?", 36, "信息提示")
If HXFYN = vbYes Then
If Data2.Recordset.RecordCount >= 0 Then
Data2.Recordset.MoveFirst
Do While Not Data2.Recordset.EOF
Data2.Recordset.Delete
Data2.Recordset.MoveNext
Loop
End If
Me.Data1.Recordset.Delete
Data1.Recordset.MoveNext
If Data1.Recordset.EOF And Data1.Recordset.RecordCount > 0 Then
Data1.Recordset.MoveFirst
End If
End If
Call rest
End Sub
Private Sub rest()
If Not Me.Data1.Recordset.BOF And Not Me.Data1.Recordset.EOF Then
If Not IsNull(Me.Data1.Recordset("类别")) Then
Me.Combo1.Text = Me.Data1.Recordset("类别")
Else
Me.Combo1.Text = " "
End If
If Not IsNull(Me.Data1.Recordset("报价方式")) Then
Me.Combo2.Text = Me.Data1.Recordset("报价方式")
Else
Me.Combo2.Text = " "
End If
Me.Data2.DatabaseName = App.Path & "\订单资料.mdb"
Me.Data2.RecordSource = "select * from 厂商报价 where 型体='" & Me.Data1.Recordset("型体") & "'"
Me.Data2.Refresh
Else
Me.Combo1.Text = " "
Me.Combo2.Text = " "
Me.Data2.DatabaseName = App.Path & "\订单资料.mdb"
Me.Data2.RecordSource = "select * from 厂商报价 where 型体=' '"
Me.Data2.Refresh
End If
If Len(Trim(Text3.Text)) > 0 Then
If filef(hxftplj & "\" & Trim(Me.Text3)) Then '判断文件是否存在
Me.Image1 = LoadPicture(hxftplj & "\" & Trim(Me.Text3))
Else
Me.Image1 = LoadPicture(App.Path & "\no.jpg")
End If
Else
Me.Image1 = LoadPicture(App.Path & "\no.jpg")
End If
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -