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

📄 删除.frm

📁 毕业设计
💻 FRM
字号:
VERSION 5.00
Begin VB.Form 更新 
   Caption         =   "更新"
   ClientHeight    =   4665
   ClientLeft      =   60
   ClientTop       =   450
   ClientWidth     =   7710
   LinkTopic       =   "Form1"
   ScaleHeight     =   4665
   ScaleWidth      =   7710
   StartUpPosition =   3  '窗口缺省
   Begin VB.CommandButton Command6 
      Caption         =   "编号查询"
      Height          =   375
      Left            =   5160
      TabIndex        =   19
      Top             =   720
      Width           =   1095
   End
   Begin VB.TextBox Text9 
      Height          =   375
      Left            =   1320
      TabIndex        =   18
      Top             =   720
      Width           =   3135
   End
   Begin VB.TextBox Text2 
      Height          =   375
      Left            =   1320
      TabIndex        =   16
      Top             =   2040
      Width           =   1695
   End
   Begin VB.CommandButton Command5 
      Caption         =   "卡号查询"
      Height          =   375
      Left            =   5160
      TabIndex        =   14
      Top             =   120
      Width           =   1095
   End
   Begin VB.TextBox Text8 
      Height          =   375
      Left            =   1320
      TabIndex        =   12
      Top             =   120
      Width           =   3135
   End
   Begin VB.TextBox Text7 
      Height          =   375
      Left            =   5280
      TabIndex        =   10
      Top             =   2040
      Width           =   1695
   End
   Begin VB.CommandButton Command4 
      Caption         =   "删除"
      Height          =   495
      Left            =   1800
      TabIndex        =   9
      Top             =   3960
      Width           =   1095
   End
   Begin VB.CommandButton Command3 
      Caption         =   "修改"
      Height          =   495
      Left            =   3240
      TabIndex        =   8
      Top             =   3960
      Width           =   1095
   End
   Begin VB.TextBox Text1 
      Height          =   375
      Left            =   1320
      TabIndex        =   4
      Top             =   1440
      Width           =   1695
   End
   Begin VB.TextBox Text3 
      Height          =   390
      Left            =   1320
      TabIndex        =   3
      Top             =   2640
      Width           =   1695
   End
   Begin VB.TextBox Text5 
      Height          =   375
      Left            =   5280
      TabIndex        =   2
      Top             =   1440
      Width           =   1695
   End
   Begin VB.CommandButton Command1 
      Caption         =   "退货"
      Height          =   495
      Left            =   4680
      TabIndex        =   1
      Top             =   3960
      Width           =   1095
   End
   Begin VB.CommandButton Command2 
      Caption         =   "返回"
      Height          =   495
      Left            =   6120
      TabIndex        =   0
      Top             =   3960
      Width           =   1095
   End
   Begin VB.Label Label9 
      Caption         =   "输入编号"
      Height          =   375
      Left            =   240
      TabIndex        =   17
      Top             =   720
      Width           =   855
   End
   Begin VB.Label Label1 
      Caption         =   "卡号编号"
      Height          =   375
      Left            =   240
      TabIndex        =   15
      Top             =   1560
      Width           =   975
   End
   Begin VB.Label Label8 
      Caption         =   "输入卡号"
      Height          =   375
      Left            =   240
      TabIndex        =   13
      Top             =   240
      Width           =   1335
   End
   Begin VB.Label Label7 
      Caption         =   "卡  号"
      Height          =   375
      Left            =   240
      TabIndex        =   11
      Top             =   2160
      Width           =   735
   End
   Begin VB.Label Label2 
      Caption         =   "类   型"
      Height          =   375
      Left            =   240
      TabIndex        =   7
      Top             =   2760
      Width           =   735
   End
   Begin VB.Label Label4 
      Caption         =   "价  格"
      Height          =   375
      Left            =   4200
      TabIndex        =   6
      Top             =   1560
      Width           =   975
   End
   Begin VB.Label Label6 
      Caption         =   "联系电话"
      Height          =   495
      Left            =   4200
      TabIndex        =   5
      Top             =   2160
      Width           =   735
   End
End
Attribute VB_Name = "更新"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
If Text1.Text = "" Then
MsgBox ("没有选定商品!")
Else
Dim conn As New ADODB.Connection
conn.ConnectionString = "file name=connect.udl"
conn.Open
conn.Execute " delete from 库存 where 卡号编号 like '" + Text1.Text + "'   "
conn.Execute "insert into 退货信息 (卡号,类型,价格) values ('" + Text2.Text + "','" + Text3.Text + "','" + Text5.Text + "')   "
Text1.Text = ""
Text2.Text = ""
Text3.Text = ""

Text5.Text = ""

Text7.Text = ""
Text8.Text = ""
conn.Close
End If
End Sub

Private Sub Command2_Click()
Unload 更新
电信进销存管理系统.Show
End Sub

Private Sub Command3_Click()
If Text1.Text = "" Then
MsgBox ("没有选定商品!")
Else
Dim conn As New ADODB.Connection
conn.ConnectionString = "file name=connect.udl"
conn.Open
conn.Execute "update 库存 set 卡号='" + Text2.Text + "',类型='" + Text3.Text + "' ,价格= '" + Text5.Text + "',联系电话='" + Text7.Text + "' where 卡号编号 like '" + Text1.Text + "' "
Text1.Text = ""
Text2.Text = ""
Text3.Text = ""
Text5.Text = ""
Text7.Text = ""
conn.Close
End If
End Sub

Private Sub Command4_Click()
If Text1.Text = "" Then
MsgBox ("没有选定商品!")
Else
Dim conn As New ADODB.Connection
conn.ConnectionString = "file name=connect.udl"
conn.Open
conn.Execute " delete from 库存 where 卡号编号 like '" + Text1.Text + "'   "

Text1.Text = ""
Text2.Text = ""
Text3.Text = ""
conn.Close
End If
End Sub

Private Sub Command5_Click()
Dim conn As New ADODB.Connection
Dim rs As New ADODB.Recordset
conn.ConnectionString = "file name=connect.udl"
conn.Open
rs.ActiveConnection = conn
rs.Open "select * from 库存 where 卡号= '" + Text8.Text + "'  ", , adOpenKeyset, adLockOptimistic, adCmdText
If rs.EOF Then
    MsgBox ("无此商品!")
Else
    Text1.Text = rs!卡号编号
    Text2.Text = rs!卡号
    Text3.Text = rs!类型
    Text5.Text = rs!价格
    Text7.Text = rs!联系电话
End If

rs.Close
conn.Close
End Sub

Private Sub Command6_Click()
Dim conn As New ADODB.Connection
Dim rs As New ADODB.Recordset
conn.ConnectionString = "file name=connect.udl"
conn.Open
rs.ActiveConnection = conn
rs.Open "select * from 库存 where 卡号编号 like '" + Text9.Text + "'  ", , adOpenKeyset, adLockOptimistic, adCmdText
If rs.EOF Then
    MsgBox ("无此商品!")
Else
    Text1.Text = rs!卡号编号
    Text2.Text = rs!卡号
    Text3.Text = rs!类型
    Text5.Text = rs!价格
    Text7.Text = rs!联系电话
End If

rs.Close
conn.Close
End Sub

⌨️ 快捷键说明

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