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

📄 goodsmodify.frm

📁 即时通讯
💻 FRM
📖 第 1 页 / 共 2 页
字号:
VERSION 5.00
Begin VB.Form goodsmodify 
   BorderStyle     =   1  'Fixed Single
   Caption         =   "商品修改"
   ClientHeight    =   3690
   ClientLeft      =   45
   ClientTop       =   330
   ClientWidth     =   5325
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MinButton       =   0   'False
   ScaleHeight     =   3690
   ScaleWidth      =   5325
   StartUpPosition =   3  '窗口缺省
   Begin VB.Frame Frame2 
      Height          =   650
      Left            =   0
      TabIndex        =   16
      Top             =   3000
      Width           =   5295
      Begin VB.CommandButton save_cmd 
         Caption         =   "确认(&S)"
         Default         =   -1  'True
         Height          =   375
         Left            =   2760
         TabIndex        =   19
         Top             =   170
         Width           =   975
      End
      Begin VB.CommandButton cancel_cmd 
         Caption         =   "取消(&C)"
         Height          =   375
         Left            =   3960
         TabIndex        =   18
         Top             =   170
         Width           =   975
      End
      Begin VB.CommandButton xz_cmd 
         Caption         =   "新增(&A)"
         Height          =   375
         Left            =   1560
         TabIndex        =   17
         Top             =   170
         Width           =   975
      End
   End
   Begin VB.Frame Frame1 
      Height          =   3015
      Left            =   0
      TabIndex        =   0
      Top             =   0
      Width           =   5295
      Begin VB.TextBox Text1 
         Enabled         =   0   'False
         Height          =   300
         Left            =   840
         TabIndex        =   15
         Top             =   240
         Width           =   1575
      End
      Begin VB.TextBox Text6 
         Enabled         =   0   'False
         Height          =   300
         Left            =   3480
         TabIndex        =   13
         Text            =   "0"
         Top             =   1200
         Width           =   1695
      End
      Begin VB.TextBox Text7 
         Height          =   900
         Left            =   840
         MultiLine       =   -1  'True
         ScrollBars      =   2  'Vertical
         TabIndex        =   12
         Top             =   1680
         Width           =   4335
      End
      Begin VB.TextBox Text5 
         Enabled         =   0   'False
         Height          =   300
         Left            =   840
         TabIndex        =   11
         Top             =   1200
         Width           =   1575
      End
      Begin VB.TextBox presetprice 
         Height          =   300
         Left            =   3480
         TabIndex        =   10
         Top             =   720
         Width           =   1695
      End
      Begin VB.TextBox Text3 
         Height          =   300
         Left            =   840
         TabIndex        =   9
         Top             =   720
         Width           =   1575
      End
      Begin VB.TextBox bigunit 
         Height          =   300
         Left            =   3480
         TabIndex        =   8
         Top             =   240
         Width           =   1695
      End
      Begin VB.TextBox goodsname 
         Enabled         =   0   'False
         Height          =   300
         Left            =   120
         TabIndex        =   7
         Top             =   2520
         Visible         =   0   'False
         Width           =   375
      End
      Begin VB.Label Label6 
         AutoSize        =   -1  'True
         Caption         =   "完成数量"
         Height          =   180
         Left            =   2640
         TabIndex        =   14
         Top             =   1200
         Width           =   720
      End
      Begin VB.Label Label15 
         AutoSize        =   -1  'True
         Caption         =   "商品备注"
         Height          =   180
         Left            =   110
         TabIndex        =   6
         Top             =   1680
         Width           =   705
      End
      Begin VB.Label Label5 
         AutoSize        =   -1  'True
         Caption         =   "金额"
         Height          =   180
         Left            =   420
         TabIndex        =   5
         Top             =   1245
         Width           =   360
      End
      Begin VB.Label Label4 
         AutoSize        =   -1  'True
         Caption         =   "单价"
         Height          =   180
         Left            =   3000
         TabIndex        =   4
         Top             =   780
         Width           =   360
      End
      Begin VB.Label Label3 
         AutoSize        =   -1  'True
         Caption         =   "数量"
         Height          =   180
         Left            =   420
         TabIndex        =   3
         Top             =   765
         Width           =   360
      End
      Begin VB.Label Label2 
         AutoSize        =   -1  'True
         Caption         =   "单位"
         Height          =   180
         Left            =   3000
         TabIndex        =   2
         Top             =   360
         Width           =   360
      End
      Begin VB.Label Label1 
         AutoSize        =   -1  'True
         Caption         =   "商品名称"
         ForeColor       =   &H00FF0000&
         Height          =   180
         Left            =   60
         TabIndex        =   1
         Top             =   285
         Width           =   720
      End
   End
End
Attribute VB_Name = "goodsmodify"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
'*******************************************************
'*    模 块 名 称 :商品维护与管理
'*    功 能 描 述 :添加商品的基本信息
'*    程序员姓名  :黄朝和
'*    最后修改人  :
'*    最后修改时间:2005/08/27
'*    备        注:
'*******************************************************
Option Explicit
Public good_type                As Integer                   ' 0--修改  1--新增
Private good_name1              As String                   ' 商品名称
Private stockorderdetailid      As String                   ' 采购订单明细编号
Public s_s_supplierid           As String                   ' 表示供应商的编号
Public g_type_form              As Integer
Private m_stockorderDAO As stockorderDAO
Private m_recordset As ADODB.Recordset
Private j As Integer


Private Sub cancel_cmd_Click()
    Unload Me
End Sub

Private Sub Form_Load()
    SetToCenter Me
 Set m_stockorderDAO = New stockorderDAO
 Set m_recordset = New ADODB.Recordset
    If good_type = 0 Then                           ' 修改商品记录
        xz_cmd.Visible = False
        goodsmodify.caption = "修改商品"
        Call xgjl
    End If
    If good_type = 1 Then                           ' 增加商品记录
        xz_cmd.caption = "新增(&A)"
        goodsmodify.caption = "新增商品"
        Text6.text = 0
    End If
End Sub
Private Sub Label1_Click()
    newgoods.stockorder_form = 0
    newgoods.c_supplierid = Trim(StockOrder.suppliername.text)
    newgoods.suppliername_f = Trim(StockOrder.Text1.Tag)
    newgoods.show 1
    If Trim(newgoods.goodsid) <> "" Then
            Text1.text = Trim(newgoods.goodsname)                              '商品名称
            bigunit.text = Trim(newgoods.bigunit)                         '大单位
            presetprice.text = CDbl(Trim(newgoods.presetprice))                 '预设进价
            goodsname.text = Trim(newgoods.goodsid)                      '商品编号
    
        Dim retg As Boolean
            retg = m_stockorderDAO.judge_stockorderdetail(m_recordset, Trim(StockOrder.suppliername.text), Trim(newgoods.goodsid))
    If retg Then
        presetprice.text = Trim(m_recordset.Fields("单价"))
    End If
            For j = 1 To StockOrder.MSHFlexGrid1.Rows - 1
                    If Trim(StockOrder.MSHFlexGrid1.TextMatrix(j, 1)) = Trim(Trim(newgoods.goodsid)) Then
                        MainForm.g_msgText = "对不起该商品已经存在,请选择添加其他的商品!!"
                        Call HMsgBox(MainForm.g_msgText, 0, 1)
                        Text1.text = ""
                        bigunit.text = ""
                        presetprice.text = 0

⌨️ 快捷键说明

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