📄 frmrukumx.frm
字号:
VERSION 5.00
Object = "{5E9E78A0-531B-11CF-91F6-C2863C385E30}#1.0#0"; "msflxgrd.ocx"
Object = "{86CF1D34-0C5F-11D2-A9FC-0000F8754DA1}#2.0#0"; "mscomct2.ocx"
Begin VB.Form frmRukuMX
BorderStyle = 1 'Fixed Single
Caption = "入库商品明细"
ClientHeight = 7800
ClientLeft = 45
ClientTop = 435
ClientWidth = 10170
Icon = "frmRukuMX.frx":0000
LinkTopic = "Form1"
MDIChild = -1 'True
ScaleHeight = 7800
ScaleWidth = 10170
Begin VB.PictureBox Picture1
Height = 7695
Left = 60
ScaleHeight = 7635
ScaleWidth = 10005
TabIndex = 0
Top = 60
Width = 10065
Begin Manage.xpcmdbutton cmdQuery
Height = 405
Left = 7260
TabIndex = 1
Top = 210
Width = 1425
_ExtentX = 2514
_ExtentY = 714
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
End
Begin MSComCtl2.DTPicker dtpEnd
Height = 285
Left = 4350
TabIndex = 2
Top = 270
Width = 2145
_ExtentX = 3784
_ExtentY = 503
_Version = 393216
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Format = 20054017
CurrentDate = 37689
End
Begin MSComCtl2.DTPicker dtpBegin
Height = 285
Left = 990
TabIndex = 3
Top = 270
Width = 2145
_ExtentX = 3784
_ExtentY = 503
_Version = 393216
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Format = 20054017
CurrentDate = 37689
End
Begin MSFlexGridLib.MSFlexGrid Grid
Height = 6075
Left = 30
TabIndex = 4
Top = 840
Width = 9945
_ExtentX = 17542
_ExtentY = 10716
_Version = 393216
Cols = 11
AllowUserResizing= 1
Appearance = 0
FormatString = " 商品编码 |^ 商品名称 |^ 进价|^ 单位|^ 数量|^ 合计|^ 发票号|^ 进货日期|^ 入库单据号|^ 入库类别|^ 供应商"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "起始自"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 210
Index = 0
Left = 300
TabIndex = 10
Top = 330
Width = 630
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "结束至"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 210
Index = 1
Left = 3660
TabIndex = 9
Top = 330
Width = 630
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "总计"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 210
Index = 2
Left = 3540
TabIndex = 8
Top = 7200
Width = 420
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "合计"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 210
Index = 3
Left = 6360
TabIndex = 7
Top = 7200
Width = 420
End
Begin VB.Label lblCount
Alignment = 1 'Right Justify
Caption = "0笔"
BeginProperty Font
Name = "宋体"
Size = 12
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 255
Left = 4110
TabIndex = 6
Top = 7170
Width = 1875
End
Begin VB.Label lblSum
Alignment = 1 'Right Justify
Caption = "0.00元"
BeginProperty Font
Name = "宋体"
Size = 12
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 255
Left = 7050
TabIndex = 5
Top = 7170
Width = 1815
End
End
End
Attribute VB_Name = "frmRukuMX"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Private Sub cmdQuery_Click()
Dim Rst As ADODB.Recordset
Dim SQL As String
SQL = "select * from v_ruku_list where indate between '" & _
Format(dtpBegin.Value, "yyyy-mm-dd") & "' and '" & Format(dtpEnd.Value, "yyyy-mm-dd") & "'"
FillGrid " 商品编码 |^ 商品名称 |^ 进价|^ 单位|^ 数量|^ 合计|^ 发票号|^ 进货日期|^ 入库单据号|^ 入库类别|^ 供应商", _
SQL, Grid, 11
Set Rst = New ADODB.Recordset
Rst.CursorLocation = adUseClient
SQL = "select count(*) from v_ruku_list where indate between '" & _
Format(dtpBegin.Value, "yyyy-mm-dd") & "' and '" & Format(dtpEnd.Value, "yyyy-mm-dd") & "'"
Rst.Open SQL, Conn, adOpenDynamic, adLockReadOnly, adCmdText
lblCount.Caption = CStr(Rst.Fields(0)) & " 笔"
Set Rst = New ADODB.Recordset
Rst.CursorLocation = adUseClient
SQL = "select sum(sum) from v_ruku_list where indate between '" & _
Format(dtpBegin.Value, "yyyy-mm-dd") & "' and '" & Format(dtpEnd.Value, "yyyy-mm-dd") & "'"
Rst.Open SQL, Conn, adOpenDynamic, adLockReadOnly, adCmdText
If Not IsNull(Rst.Fields(0)) Then lblSum.Caption = Format(CStr(Rst.Fields(0)), "0.00") & " 元" Else lblSum.Caption = "0.00 元"
Set Rst = Nothing
End Sub
Private Sub Form_Load()
dtpBegin.Value = Date$
dtpEnd.Value = Date$
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -