⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 frmwareslist.frm

📁 针对农资系统的管理模式而开发的业务部门与财务部门的转账模式和过程
💻 FRM
📖 第 1 页 / 共 3 页
字号:
VERSION 5.00
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
Object = "{CDE57A40-8B86-11D0-B3C6-00A0C90AEA82}#1.0#0"; "MSDATGRD.OCX"
Object = "{F0D2F211-CCB0-11D0-A316-00AA00688B10}#1.0#0"; "MSDATLST.OCX"
Begin VB.Form frmWaresList 
   Caption         =   "库存商品目录"
   ClientHeight    =   5835
   ClientLeft      =   60
   ClientTop       =   345
   ClientWidth     =   9900
   Icon            =   "frmWaresList.frx":0000
   KeyPreview      =   -1  'True
   LinkTopic       =   "Form1"
   MDIChild        =   -1  'True
   ScaleHeight     =   5835
   ScaleWidth      =   9900
   WindowState     =   2  'Maximized
   Begin MSDataListLib.DataList lstMode 
      Height          =   900
      Left            =   7920
      TabIndex        =   7
      Top             =   1560
      Visible         =   0   'False
      Width           =   1575
      _ExtentX        =   2778
      _ExtentY        =   1588
      _Version        =   393216
      Appearance      =   0
      ListField       =   ""
      BoundColumn     =   ""
   End
   Begin VB.Frame FrameSplit 
      Appearance      =   0  'Flat
      BackColor       =   &H00C0C0C0&
      ForeColor       =   &H80000008&
      Height          =   5175
      Left            =   3360
      TabIndex        =   14
      Top             =   600
      Width           =   135
   End
   Begin VB.Frame FrameType 
      Caption         =   "商品类别"
      Height          =   5175
      Left            =   50
      TabIndex        =   12
      Top             =   600
      Width           =   3375
      Begin MSComctlLib.TreeView trvType 
         Height          =   4335
         Left            =   120
         TabIndex        =   3
         Top             =   240
         Width           =   3135
         _ExtentX        =   5530
         _ExtentY        =   7646
         _Version        =   393217
         HideSelection   =   0   'False
         Indentation     =   529
         LabelEdit       =   1
         LineStyle       =   1
         Style           =   7
         HotTracking     =   -1  'True
         Appearance      =   1
      End
      Begin VB.PictureBox picTypeButtons 
         Appearance      =   0  'Flat
         BackColor       =   &H00C0C0C0&
         BorderStyle     =   0  'None
         ForeColor       =   &H80000008&
         Height          =   495
         Left            =   120
         ScaleHeight     =   495
         ScaleWidth      =   3015
         TabIndex        =   15
         Top             =   4560
         Width           =   3015
         Begin VB.CommandButton cmdEditType 
            Caption         =   "修改(&M)"
            Height          =   315
            Left            =   1080
            TabIndex        =   1
            Top             =   120
            Width           =   855
         End
         Begin VB.CommandButton cmdDelType 
            Caption         =   "删除(&R)"
            Height          =   315
            Left            =   2160
            TabIndex        =   2
            Top             =   120
            Width           =   855
         End
         Begin VB.CommandButton cmdAddType 
            Caption         =   "新增(&N)"
            Height          =   315
            Left            =   0
            TabIndex        =   0
            Top             =   120
            Width           =   855
         End
      End
   End
   Begin VB.Frame FrameList 
      Caption         =   "商品目录"
      Height          =   5175
      Left            =   3480
      TabIndex        =   13
      Top             =   600
      Width           =   6375
      Begin MSDataGridLib.DataGrid grdList 
         Height          =   4335
         Left            =   120
         TabIndex        =   8
         Top             =   240
         Width           =   6135
         _ExtentX        =   10821
         _ExtentY        =   7646
         _Version        =   393216
         AllowUpdate     =   0   'False
         BackColor       =   12632256
         HeadLines       =   2
         RowHeight       =   15
         TabAction       =   2
         WrapCellPointer =   -1  'True
         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.PictureBox picListButtons 
         Appearance      =   0  'Flat
         BackColor       =   &H00C0C0C0&
         BorderStyle     =   0  'None
         ForeColor       =   &H80000008&
         Height          =   495
         Left            =   720
         ScaleHeight     =   495
         ScaleWidth      =   4935
         TabIndex        =   16
         Top             =   4560
         Width           =   4935
         Begin VB.CommandButton cmdClose 
            Caption         =   "关闭(&X)"
            CausesValidation=   0   'False
            Height          =   315
            Left            =   3960
            TabIndex        =   9
            Top             =   120
            Width           =   975
         End
         Begin VB.CommandButton cmdPrintList 
            Caption         =   "打印(&P)"
            Height          =   315
            Left            =   2640
            TabIndex        =   6
            Top             =   120
            Width           =   975
         End
         Begin VB.CommandButton cmdAddList 
            Caption         =   "增加(&A)"
            Height          =   315
            Left            =   0
            TabIndex        =   4
            Top             =   120
            Width           =   975
         End
         Begin VB.CommandButton cmdDelList 
            Caption         =   "删除(&D)"
            Height          =   315
            Left            =   1320
            TabIndex        =   5
            Top             =   120
            Width           =   975
         End
      End
   End
   Begin VB.Label lblTitle 
      Alignment       =   2  'Center
      AutoSize        =   -1  'True
      BackStyle       =   0  'Transparent
      Caption         =   "库存商品目录"
      BeginProperty Font 
         Name            =   "隶书"
         Size            =   26.25
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H00FF0000&
      Height          =   525
      Index           =   0
      Left            =   3480
      TabIndex        =   10
      Top             =   0
      Width           =   3165
   End
   Begin VB.Label lblTitle 
      Alignment       =   2  'Center
      AutoSize        =   -1  'True
      BackStyle       =   0  'Transparent
      Caption         =   "库存商品目录"
      BeginProperty Font 
         Name            =   "隶书"
         Size            =   26.25
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H00FFFFFF&
      Height          =   525
      Index           =   1
      Left            =   3510
      TabIndex        =   11
      Top             =   30
      Width           =   3165
   End
End
Attribute VB_Name = "frmWaresList"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Dim WithEvents m_DatListRs As ADODB.Recordset
Attribute m_DatListRs.VB_VarHelpID = -1
Dim m_ModeRs As ADODB.Recordset

Private Const BLACK_COLOR As Long = &H80000008      '黑色
Private Const GREY_COLOR As Long = &HC0C0C0         '灰色
Private Const WHITE_COLOR As Long = &HFFFFFF        '白色
Private Const ROOT_KEY As String = "Root"
Private Const ROOT_TEXT As String = "商品类别"
Dim m_sParentCode As String
Dim CodeCol As Integer, NameCol As Integer, SpecCol As Integer, MeasCol As Integer, ThisCodeCol As Integer
Dim ModeCol As Integer, ModeNameCol As Integer, AreaCol As Integer, FLagCol As Integer
Dim m_bEdit As Boolean

'///////////////////////////////////////
'//
Property Let OperatorPower(bEdit As Boolean)
    m_bEdit = bEdit
End Property

'///////////////////////////////////////
'//
Private Sub SetOkCheck()
    Dim bIsRoot As Boolean, bIsLeaf As Boolean, bEmptyList As Boolean
    Dim nSeriesNum As Integer
    
    With trvType
        bIsRoot = IIf(.SelectedItem = .Nodes(ROOT_KEY), True, False)
        bIsLeaf = IIf(Not bIsRoot And .SelectedItem.Children = 0, True, False)
        If bIsRoot Then
            nSeriesNum = 0
        Else
            nSeriesNum = GetThisSeriesNum(Mid(.SelectedItem.Key, 2)) 'lz
        End If
    End With
    
    If m_DatListRs Is Nothing Then
        bEmptyList = True
    Else
        bEmptyList = IIf(m_DatListRs.RecordCount = 0, True, False)
    End If
    
    cmdAddType.Enabled = nSeriesNum < m_gSeriesNum - 1 And Not (bIsLeaf And Not bEmptyList) And m_bEdit
    cmdEditType.Enabled = Not bIsRoot And m_bEdit
    cmdDelType.Enabled = Not bIsRoot And bEmptyList And m_bEdit
    

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -