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

📄 出库更新窗口.frm

📁 此为库存管理系统!使用了VB开发工具开发
💻 FRM
📖 第 1 页 / 共 2 页
字号:
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H0000FFFF&
         Height          =   375
         Left            =   120
         TabIndex        =   10
         Top             =   4440
         Width           =   975
      End
      Begin VB.Label Label6 
         BackColor       =   &H00C00000&
         Caption         =   "日期:"
         BeginProperty Font 
            Name            =   "楷体_GB2312"
            Size            =   10.5
            Charset         =   134
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H0000FFFF&
         Height          =   375
         Left            =   120
         TabIndex        =   9
         Top             =   3720
         Width           =   855
      End
      Begin VB.Label Label9 
         BackColor       =   &H00C00000&
         Caption         =   "送货人名称:"
         BeginProperty Font 
            Name            =   "楷体_GB2312"
            Size            =   10.5
            Charset         =   134
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H0000FFFF&
         Height          =   375
         Left            =   120
         TabIndex        =   8
         Top             =   5760
         Width           =   1575
      End
      Begin VB.Label Label8 
         BackColor       =   &H00C00000&
         Caption         =   "入库单位名称:"
         BeginProperty Font 
            Name            =   "楷体_GB2312"
            Size            =   10.5
            Charset         =   134
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H0000FFFF&
         Height          =   375
         Left            =   120
         TabIndex        =   7
         Top             =   5040
         Width           =   1815
      End
      Begin VB.Label Label5 
         BackColor       =   &H00C00000&
         Caption         =   "数量:"
         BeginProperty Font 
            Name            =   "楷体_GB2312"
            Size            =   10.5
            Charset         =   134
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H0000FFFF&
         Height          =   375
         Left            =   120
         TabIndex        =   6
         Top             =   3000
         Width           =   855
      End
      Begin VB.Label Label4 
         BackColor       =   &H00C00000&
         Caption         =   "规格:"
         BeginProperty Font 
            Name            =   "楷体_GB2312"
            Size            =   10.5
            Charset         =   134
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H0000FFFF&
         Height          =   375
         Left            =   120
         TabIndex        =   5
         Top             =   2280
         Width           =   855
      End
      Begin VB.Label Label3 
         BackColor       =   &H00C00000&
         Caption         =   "型号:"
         BeginProperty Font 
            Name            =   "楷体_GB2312"
            Size            =   10.5
            Charset         =   134
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H0000FFFF&
         Height          =   375
         Left            =   120
         TabIndex        =   4
         Top             =   1560
         Width           =   855
      End
      Begin VB.Label Label2 
         BackColor       =   &H00C00000&
         Caption         =   "生产厂家:"
         BeginProperty Font 
            Name            =   "楷体_GB2312"
            Size            =   10.5
            Charset         =   134
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H0000FFFF&
         Height          =   375
         Left            =   120
         TabIndex        =   3
         Top             =   960
         Width           =   1335
      End
      Begin VB.Label Label1 
         BackColor       =   &H00C00000&
         Caption         =   "商品名称:"
         BeginProperty Font 
            Name            =   "楷体_GB2312"
            Size            =   10.5
            Charset         =   134
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H0000FFFF&
         Height          =   375
         Left            =   120
         TabIndex        =   2
         Top             =   360
         Width           =   1335
      End
   End
End
Attribute VB_Name = "Form10"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim temp As Integer

Private Sub Command1_Click()
 Form2.Adodc1.Recordset.Fields(0) = Text1.Text
    Form2.Adodc1.Recordset.Fields(1) = Text2.Text
    Form2.Adodc1.Recordset.Fields(2) = Text3.Text
    Form2.Adodc1.Recordset.Fields(3) = Text4.Text
    Form2.Adodc1.Recordset.Fields(4) = Val(Text5.Text)
    Form2.Adodc1.Recordset.Fields(5) = Text6.Text
    Form2.Adodc1.Recordset.Fields(6) = Text7.Text
    Form2.Adodc1.Recordset.Fields(7) = Text8.Text
   Form2.Adodc1.Recordset.Fields(8) = Text9.Text
   
   Form2.Adodc1.Recordset.update
   Form2.DataGrid1.Refresh
   
     Set rst = New ADODB.Recordset
       Set conn = New ADODB.Connection

        conn.ConnectionString = "Provider=SQLOLEDB.1;password=huangtao;User ID=huangtao;Initial Catalog=canku"
        conn.Open

 'Text10.Text = Text1.Text
 
      sql = "select * from 现有库存表 where 商品名称='" & Text1.Text & "'"
 
      rst.Open sql, conn, 1, 3
      rst(1).Value = rst(1).Value + temp - Form2.Adodc1.Recordset.Fields(4)
      rst.update
      
      Form3.DataGrid1.Refresh
      
   
    MsgBox "更新成功", , "库存管理系统"
   
        
'--------------------显示更改信息----------------------------
   Form2.Text10 = rst(0).Value
   Form2.Text11 = rst(1).Value
   Form2.Text12 = rst(2).Value
   Form2.Text13 = rst(3).Value
      
   
   Form10.Hide
   
End Sub

Private Sub Command2_Click()
Form10.Hide

End Sub

Private Sub Form_Load()
   Text1.Text = Form2.Adodc1.Recordset.Fields(0)
   Text2.Text = Form2.Adodc1.Recordset.Fields(1)
   Text3.Text = Form2.Adodc1.Recordset.Fields(2)
   Text4.Text = Form2.Adodc1.Recordset.Fields(3)
   Text5.Text = Form2.Adodc1.Recordset.Fields(4)
   Text6.Text = Form2.Adodc1.Recordset.Fields(5)
   Text7.Text = Form2.Adodc1.Recordset.Fields(6)
   Text8.Text = Form2.Adodc1.Recordset.Fields(7)
   Text9.Text = Form2.Adodc1.Recordset.Fields(8)
   
   temp = Form2.Adodc1.Recordset.Fields(4)
   
End Sub


⌨️ 快捷键说明

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