📄 frmadaptcard.frm
字号:
VERSION 5.00
Object = "{D252F124-F62C-11D1-9ABD-444553540000}#1.0#0"; "GADATE.DLL"
Object = "{5E9E78A0-531B-11CF-91F6-C2863C385E30}#1.0#0"; "MSFLXGRD.OCX"
Object = "{F6125AB1-8AB1-11CE-A77F-08002B2F4E98}#2.0#0"; "MSRDC20.OCX"
Begin VB.Form frmAdaptCard
Caption = "调整商品价格"
ClientHeight = 4830
ClientLeft = 60
ClientTop = 345
ClientWidth = 7095
HelpContextID = 11001
KeyPreview = -1 'True
LinkTopic = "Form1"
LockControls = -1 'True
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 4830
ScaleWidth = 7095
StartUpPosition = 2 '屏幕中心
Begin MSRDC.MSRDC datAdjust
Height = 360
Left = 5790
Top = 4290
Visible = 0 'False
Width = 1200
_ExtentX = 2117
_ExtentY = 635
_Version = 393216
Options = 0
CursorDriver = 0
BOFAction = 0
EOFAction = 0
RecordsetType = 1
LockType = 3
QueryType = 0
Prompt = 3
Appearance = 1
QueryTimeout = 30
RowsetSize = 100
LoginTimeout = 15
KeysetSize = 0
MaxRows = 0
ErrorThreshold = -1
BatchSize = 15
BackColor = -2147483643
ForeColor = -2147483640
Enabled = -1 'True
ReadOnly = 0 'False
Appearance = -1 'True
DataSourceName = ""
RecordSource = ""
UserName = ""
Password = ""
Connect = ""
LogMessages = ""
Caption = "MSRDC1"
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.TextBox txtInput
Appearance = 0 'Flat
Height = 270
Left = 1770
MaxLength = 12
TabIndex = 6
Top = 2250
Visible = 0 'False
Width = 1575
End
Begin MSFlexGridLib.MSFlexGrid msgItem
Bindings = "frmAdaptCard.frx":0000
Height = 4125
Left = 120
TabIndex = 7
Top = 540
Width = 5535
_ExtentX = 9763
_ExtentY = 7276
_Version = 393216
Rows = 5
Cols = 10
FixedCols = 0
RowHeightMin = 270
BackColorBkg = 16777215
GridLines = 0
End
Begin VB.CommandButton cmdOK
Caption = "栏目设置"
Height = 350
Index = 8
Left = 5790
TabIndex = 16
Top = 3900
UseMaskColor = -1 'True
Width = 1215
End
Begin VB.CommandButton cmdOK
Caption = "填充单价"
Enabled = 0 'False
Height = 350
Index = 7
Left = 5790
TabIndex = 15
Top = 3480
UseMaskColor = -1 'True
Width = 1215
End
Begin VB.CommandButton cmdOK
Caption = "固定单价"
Enabled = 0 'False
Height = 350
Index = 6
Left = 5790
TabIndex = 14
Top = 3060
UseMaskColor = -1 'True
Width = 1215
End
Begin VB.CommandButton cmdOK
Caption = "复制单价"
Enabled = 0 'False
Height = 350
Index = 5
Left = 5790
TabIndex = 13
Top = 2640
UseMaskColor = -1 'True
Width = 1215
End
Begin VB.CommandButton cmdOK
Caption = "全部取消"
Height = 350
Index = 4
Left = 5790
TabIndex = 12
Top = 2220
UseMaskColor = -1 'True
Width = 1215
End
Begin VB.CommandButton cmdOK
Caption = "条件选择"
Height = 350
Index = 3
Left = 5790
TabIndex = 11
Top = 1800
UseMaskColor = -1 'True
Width = 1215
End
Begin VB.CommandButton cmdOK
Caption = "全部选择"
Height = 350
Index = 2
Left = 5790
TabIndex = 10
Top = 1380
UseMaskColor = -1 'True
Width = 1215
End
Begin VB.CommandButton cmdOK
Cancel = -1 'True
Height = 350
Index = 1
Left = 5790
Style = 1 'Graphical
TabIndex = 9
Tag = "1002"
Top = 960
UseMaskColor = -1 'True
Width = 1215
End
Begin VB.CommandButton cmdOK
Height = 350
Index = 0
Left = 5790
Style = 1 'Graphical
TabIndex = 8
Tag = "1001"
Top = 540
UseMaskColor = -1 'True
Width = 1215
End
Begin VB.ComboBox cboItem
Height = 300
Index = 1
Left = 4140
Style = 2 'Dropdown List
TabIndex = 3
Top = 120
Width = 885
End
Begin VB.ComboBox cboItem
Height = 300
Index = 0
Left = 1170
Style = 2 'Dropdown List
TabIndex = 1
Top = 120
Width = 1875
End
Begin GACALENDARLibCtl.Calendar dtePrice
Height = 285
Left = 5760
OleObjectBlob = "frmAdaptCard.frx":0018
TabIndex = 5
Top = 120
Width = 1245
End
Begin VB.Label lblItem
AutoSize = -1 'True
Caption = "日期(&D)"
Height = 180
Index = 2
Left = 5130
TabIndex = 4
Top = 180
Width = 630
End
Begin VB.Label lblItem
AutoSize = -1 'True
Caption = "调整价格(&P)"
Height = 180
Index = 1
Left = 3120
TabIndex = 2
Top = 180
Width = 990
End
Begin VB.Label lblItem
AutoSize = -1 'True
Caption = "商品类型(&T)"
Height = 180
Index = 0
Left = 150
TabIndex = 0
Top = 180
Width = 990
End
End
Attribute VB_Name = "frmAdaptCard"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
' 调整商品价格卡片
' 作者:苏涛
' 日期:1998.07.04
'
' 功能:调整选定的单位的商品价格
'
' 接口: ShowCard 显示和进入调整商品价格卡片
'
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Option Explicit
Option Compare Text
Private Const mintViewId = 112
Private mintSelCount As Integer
Private mbytDec As Byte
Private mblnIsAdjust As Boolean 'TRUE--CLICK调整价格CBO,用于保存数据时选择列
Private mblnIsInit As Boolean
Private mblnIsChanged As Boolean
Private mlngcboID(0 To 1) As Long '上次CBOITEM的LISTINDEX
Private mintCol As Integer
Private WithEvents mclsGrid As Grid
Attribute mclsGrid.VB_VarHelpID = -1
Private mlngRow As Long
Private mstrArr(0 To 3) As String
Public Property Let IsChanged(ByVal vNewValue As Boolean)
mblnIsChanged = vNewValue
End Property
Public Sub ShowCard()
Show vbModal
End Sub
Private Sub cboItem_Click(index As Integer)
If mblnIsInit Then Exit Sub
If mlngcboID(index) = cboItem(index).ListIndex Then Exit Sub
If mblnIsChanged Then
mblnIsAdjust = (index = 1)
If ShowMsg(hwnd, "当前商品价格已被修改,是否保存?", vbQuestion + _
vbYesNo, Caption) = vbYes Then SaveCard
End If
mlngcboID(index) = cboItem(index).ListIndex
InitGrid cboItem(1).ListIndex = 0
mintSelCount = 0
SetButton
' msgItem.SetFocus
End Sub
Private Sub cmdOK_Click(index As Integer)
Dim blnOK As Boolean, i As Integer, iSelNum As Integer
Dim recTemplete As rdoResultset
Dim strCon As String, strCon1 As String, strID As String
Dim strSql As String, strWhereOf As String
Select Case index
Case 0 '确定
If Me.ActiveControl.Name = "msgItem" Then
msgItem_KeyPress vbKeyReturn
Exit Sub
ElseIf Me.ActiveControl.Name = "txtInput" Then
txtInput_KeyUp vbKeyReturn, 0
Exit Sub
End If
SaveCard
Unload Me
Case 1 '取消
Unload Me
Case 2 '全部选择
If msgItem.Rows = 1 Then Exit Sub
For i = 1 To msgItem.Rows - 1
'If Not frmItemCard.ItemIsUsed(msgItem.TextMatrix(i, 0)) Then
If msgItem.RowHeight(i) > 0 Then
msgItem.TextMatrix(i, 1) = "√"
mintSelCount = mintSelCount + 1
End If
Next i
SetButton
Case 3 '条件选择
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -