📄 kucunguanli.frm
字号:
Width = 9615
_ExtentX = 16960
_ExtentY = 4895
_Version = 393216
HeadLines = 1
RowHeight = 15
BeginProperty HeadFont {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "宋体"
Size = 9
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ColumnCount = 2
BeginProperty Column00
DataField = ""
Caption = ""
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
BeginProperty Column01
DataField = ""
Caption = ""
BeginProperty DataFormat {6D835690-900B-11D0-9484-00A0C91110ED}
Type = 0
Format = ""
HaveTrueFalseNull= 0
FirstDayOfWeek = 0
FirstWeekOfYear = 0
LCID = 2052
SubFormatType = 0
EndProperty
EndProperty
SplitCount = 1
BeginProperty Split0
BeginProperty Column00
EndProperty
BeginProperty Column01
EndProperty
EndProperty
End
Begin VB.Label Label10
Caption = "注意:本信息与进,出库表相关联,不要随便改动,可能造成数据不一致!"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00FF8080&
Height = 495
Left = 7920
TabIndex = 28
Top = 3240
Width = 5775
End
Begin VB.Label Label6
Caption = "库存编号"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 720
TabIndex = 12
Top = 480
Width = 855
End
Begin VB.Label Label7
Caption = "备注"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 360
TabIndex = 11
Top = 2640
Width = 735
End
Begin VB.Label Label8
Caption = "库存总量"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 720
TabIndex = 10
Top = 1920
Width = 855
End
Begin VB.Label Label9
Caption = "商品名称"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 720
TabIndex = 9
Top = 1320
Width = 855
End
End
End
End
Attribute VB_Name = "kucunguanli"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
End Sub
Private Sub cmdadd_Click()
If cmdadd.Caption = "添加" Then
currentbookmark = Adodc1.Recordset.AbsolutePosition
Adodc1.Recordset.AddNew
cmdadd.Caption = "保存"
cmdadd.Caption = "保存"
cmdModify.Enabled = False
cmddelete.Enabled = False
Else
Adodc1.Recordset.Update
cmdadd.Caption = "添加"
cmdModify.Enabled = True
cmddelete.Enabled = True
'CanInput False
currentbookmark = 0
' ////////////////////////////入库
' Dim ruk As String
'Dim shp As String
' ruk = rukudanhao.Text
' shp = Combo1.Text
cn.Open
CallProcRecordSet "sp_ruku0('" & Text1.Text & "','" & Text4.Text & "')"
cn.Close
End If
End Sub
Private Sub cmdcancel_Click()
Unload Me
kucunguanli.Show
End Sub
Private Sub cmddelete_Click()
If RecordsetIsEmpty(Adodc1.Recordset) Then Exit Sub
If MsgBox("真的要删除这记录吗?", vbYesNo) = vbYes Then
Adodc1.Recordset.Delete
If RecordsetIsEmpty(Adodc1.Recordset) Then
Adodc1.Refresh
Exit Sub
End If
If Adodc1.Recordset.EOF Then Adodc1.Recordset.MoveLast
End If
End Sub
Private Sub cmddelete1_Click()
If RecordsetIsEmpty(Adodc2.Recordset) Then Exit Sub
If MsgBox("真的要删除这记录吗?", vbYesNo) = vbYes Then
Adodc2.Recordset.Delete
If RecordsetIsEmpty(Adodc2.Recordset) Then
Adodc2.Refresh
Exit Sub
End If
If Adodc2.Recordset.EOF Then Adodc2.Recordset.MoveLast
End If
End Sub
Private Sub cmdModify_Click()
If Adodc1.Recordset.AbsolutePosition < 0 Then Exit Sub
If cmdModify.Caption = "修改" Then
currentbookmark = Adodc1.Recordset.AbsolutePosition
'CanInput True
cmdModify.Caption = "保存"
'cmdModify.Enabled = False
cmddelete.Enabled = False
cmdadd.Enabled = False
Else
Adodc1.Recordset.Update
cmdModify.Caption = "修改"
cmddelete.Enabled = ture
cmdadd.Enabled = True
' CanInput False
currentbookmark = 0
End If
End Sub
Private Sub Command7_Click()
End Sub
End Sub
Private Sub cmdModify1_Click()
If Adodc2.Recordset.AbsolutePosition < 0 Then Exit Sub
If cmdModify1.Caption = "修改" Then
currentbookmark = Adodc2.Recordset.AbsolutePosition
'CanInput True
cmdModify1.Caption = "保存"
cmdModify1.Enabled = True
'cmddelete1.Enabled = False
'cmdadd1.Enabled = False
'Text6.Locked = False
'Text7.Locked = False
'Text8.Locked = False
'Text9.Locked = False
'Text10.Locked = False
cn.Open
Set DataList1.RowSource = Query("select 商品名称 from Product")
DataList1.ListField = "商品名称"
cn.Close
Else
Adodc2.Recordset.Update
cmdModify1.Caption = "修改"
'cmdadd1.Enabled = True
'cmddelete1.Enabled = ture
' CanInput False
currentbookmark = 0
End If
End Sub
Private Sub Form_Load()
Adodc1.CommandType = adCmdTable
Adodc1.RecordSource = "Product"
Adodc1.Refresh
Set DataGrid1.DataSource = Adodc1.Recordset
Adodc2.CommandType = adCmdTable
Adodc2.RecordSource = "kucunxinxibiao"
Adodc2.Refresh
Set DataGrid2.DataSource = Adodc2.Recordset
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -