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

📄 frmitemedit.frm

📁 这是一个利用VB编写的中小企业ERP。功能比较全
💻 FRM
📖 第 1 页 / 共 2 页
字号:
      Top             =   2880
      Width           =   855
   End
   Begin VB.Label Label7 
      Caption         =   "制 购"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   5640
      TabIndex        =   6
      Top             =   480
      Width           =   855
   End
   Begin VB.Label Label6 
      Caption         =   "单位"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   2880
      TabIndex        =   5
      Top             =   3480
      Width           =   735
   End
   Begin VB.Label Label5 
      Caption         =   "颜色"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   120
      TabIndex        =   4
      Top             =   3480
      Width           =   735
   End
   Begin VB.Label Label4 
      Caption         =   "规格"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   120
      TabIndex        =   3
      Top             =   2880
      Width           =   735
   End
   Begin VB.Label Label3 
      Caption         =   "图号"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   120
      TabIndex        =   2
      Top             =   1680
      Width           =   735
   End
   Begin VB.Label Label2 
      Caption         =   "货号"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   120
      TabIndex        =   1
      Top             =   1080
      Width           =   735
   End
   Begin VB.Label Label1 
      Caption         =   "机型"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   120
      TabIndex        =   0
      Top             =   480
      Width           =   735
   End
   Begin VB.Label Label23 
      Caption         =   "备 注"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   120
      TabIndex        =   17
      Top             =   4800
      Width           =   975
   End
   Begin VB.Label Label18 
      Caption         =   "包装数量"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   8400
      TabIndex        =   16
      Top             =   2280
      Width           =   1335
   End
   Begin VB.Label Label17 
      Caption         =   "包装类型"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   8400
      TabIndex        =   15
      Top             =   1680
      Width           =   1335
   End
   Begin VB.Label Label16 
      Caption         =   "包装体积"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   8400
      TabIndex        =   14
      Top             =   1080
      Width           =   1575
   End
   Begin VB.Label Label15 
      Caption         =   "包装单重"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   8400
      TabIndex        =   13
      Top             =   480
      Width           =   1455
   End
   Begin VB.Label Label14 
      Caption         =   "毛 重"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   8880
      TabIndex        =   12
      Top             =   3480
      Width           =   855
   End
   Begin VB.Label Label13 
      Caption         =   "净 重"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   15
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   5640
      TabIndex        =   11
      Top             =   3480
      Width           =   855
   End
End
Attribute VB_Name = "FrmItemEdit"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Public Modify As Boolean
Public OriItem As String
Private Sub Form_Load()
    '填充制购List单
    CmbMB.List(0) = "B购买"
    CmbMB.List(1) = "M制造"
    CmbMB.List(2) = "S外发"
    CmbMB.List(3) = "Z其他"
    '填充类型List单
    CmbIT.List(0) = "N一般"
    CmbIT.List(1) = "T工具"
    CmbIT.List(2) = "W工作中心"
    CmbIT.List(3) = "R参考"
    '填充状态List
    CmbST.List(0) = "A可用"
    CmbST.List(1) = "E工程"
    CmbST.List(2) = "P逐渐报废"
    CmbST.List(3) = "S报废"
    '填充检验List
    CmbInspect.List(0) = "Y需检验"
    CmbInspect.List(1) = "N无需检验"
    
End Sub

Private Sub LblCancel_Click()
    Unload Me
End Sub


Private Function Check() As Boolean
    If Trim(TxtItem) = "" Then
        MsgBox "请输入货号"
        TxtItem.SetFocus
        Check = False
        Exit Function
    End If
    If Trim(txtName) = "" Then
        MsgBox "请输入名称"
        txtName.SetFocus
        Check = False
        Exit Function
    End If
    
    
    Check = True
End Function


Private Sub LblOK_Click()
    
    '判断要编辑信息是否完整
    If Check = False Then
        Exit Sub
    End If
    
    With MyItem
        .Model = TxtModel.Text
        .Item = TxtItem.Text
        .Drawing = TxtDrawing.Text
        .Name = txtName.Text
        .Specification = TxtSpecification.Text
        .Color = TxtColor.Text
        .Unit = TxtUnit.Text
        .MB = CmbMB.Text
        .IT = CmbIT.Text
        .ST = CmbST.Text
        .Inspect = CmbInspect.Text
        .Capacity = TxtCapacity.Text
        .NWeight = TxtNWeight.Text
        .RWeight = TxtRWeight.Text
        .PackWeight = TxtPackWeight.Text
        .PackVolume = TxtPackVolume.Text
        .PackType = TxtPackType.Text
        .PackQty = TxtPackQty.Text
        .ProLow = TxtProLow.Text
        .ProHigh = TxtProHigh.Text
        .Valid = TxtValid.Text
        .AlarmDays = TxtAlarmDays.Text
        .Remark = TxtRemark.Text
        
        
        
        '判断操作是添加还是修改
        If Modify = False Then '判断为添加操作
            '判断待添加货号是否已经存在
            If .In_DB(TxtItem.Text) = True Then
                MsgBox "货号重复,请重新设置"
                TxtItem.SetFocus
                TxtItem.SelStart = 0
                TxtItem.SelLength = Len(TxtItem)
                Exit Sub
            Else
                .Insert '添加
                MsgBox "添加成功"
            End If
            
        Else '判断为修改操作
            .Update (OriItem)
            MsgBox "修改成功"
        End If
    End With
    Unload Me
    
End Sub


Private Sub TxtAlarmDays_KeyPress(KeyAscii As Integer)
    EnterTAB (KeyAscii)
    If In_Int(KeyAscii) = False Then
        KeyAscii = 0
    End If
End Sub


Private Sub TxtPackQty_KeyPress(KeyAscii As Integer)
    EnterTAB (KeyAscii)
    If In_Int(KeyAscii) = False Then
        KeyAscii = 0
    End If
End Sub

Private Sub TxtProHigh_KeyPress(KeyAscii As Integer)
    EnterTAB (KeyAscii)
    If In_Int(KeyAscii) = False Then
        KeyAscii = 0
    End If
End Sub

Private Sub TxtProLow_KeyPress(KeyAscii As Integer)
    EnterTAB (KeyAscii)
    If In_Int(KeyAscii) = False Then
        KeyAscii = 0
    End If
End Sub


Private Sub TxtValid_KeyPress(KeyAscii As Integer)
    EnterTAB (KeyAscii)
    If In_Int(KeyAscii) = False Then
        KeyAscii = 0
    End If
End Sub

⌨️ 快捷键说明

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