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

📄 frmsellerinfomanage.frm

📁 多方讨价还价系统
💻 FRM
字号:
VERSION 5.00
Begin VB.Form frmSellerInfomanage 
   Caption         =   "卖方信息管理"
   ClientHeight    =   4875
   ClientLeft      =   60
   ClientTop       =   450
   ClientWidth     =   7080
   LinkTopic       =   "Form1"
   ScaleHeight     =   4875
   ScaleWidth      =   7080
   StartUpPosition =   3  'Windows Default
   Begin VB.Frame Frame2 
      Caption         =   "信息管理"
      Height          =   2775
      Left            =   480
      TabIndex        =   6
      Top             =   1080
      Width           =   6015
      Begin VB.TextBox txtServeSM 
         Height          =   375
         Left            =   960
         TabIndex        =   14
         Top             =   960
         Width           =   1215
      End
      Begin VB.TextBox TxtcompanySM 
         Height          =   375
         Left            =   3240
         TabIndex        =   13
         Top             =   360
         Width           =   2655
      End
      Begin VB.TextBox txtProductionSM 
         Height          =   375
         Left            =   3240
         TabIndex        =   12
         Top             =   960
         Width           =   2655
      End
      Begin VB.TextBox txtQualitySM 
         Height          =   375
         Left            =   960
         TabIndex        =   11
         Top             =   1560
         Width           =   1215
      End
      Begin VB.TextBox txtHighpriceSM 
         Height          =   375
         Left            =   3240
         TabIndex        =   10
         Top             =   1560
         Width           =   2655
      End
      Begin VB.TextBox txtLowPriceSM 
         Height          =   375
         Left            =   3240
         TabIndex        =   9
         Top             =   2160
         Width           =   2655
      End
      Begin VB.TextBox txtStepSM 
         Height          =   375
         Left            =   960
         TabIndex        =   8
         Top             =   2160
         Width           =   1215
      End
      Begin VB.TextBox TxtsellIDSM 
         Height          =   375
         Left            =   960
         TabIndex        =   7
         Top             =   360
         Width           =   1215
      End
      Begin VB.Label Label2 
         Caption         =   "用户名"
         Height          =   375
         Left            =   120
         TabIndex        =   22
         Top             =   360
         Width           =   735
      End
      Begin VB.Label Label3 
         Caption         =   "服务系数"
         Height          =   375
         Left            =   120
         TabIndex        =   21
         Top             =   960
         Width           =   735
      End
      Begin VB.Label Label4 
         Caption         =   "单位名称"
         Height          =   375
         Left            =   2400
         TabIndex        =   20
         Top             =   360
         Width           =   735
      End
      Begin VB.Label Label5 
         Caption         =   "产品名称"
         Height          =   375
         Left            =   2400
         TabIndex        =   19
         Top             =   960
         Width           =   735
      End
      Begin VB.Label Label6 
         Caption         =   "质量系数"
         Height          =   375
         Left            =   120
         TabIndex        =   18
         Top             =   1560
         Width           =   735
      End
      Begin VB.Label Label7 
         Caption         =   "最高价格"
         Height          =   375
         Left            =   2400
         TabIndex        =   17
         Top             =   1560
         Width           =   735
      End
      Begin VB.Label Label8 
         Caption         =   "最低价格"
         Height          =   375
         Left            =   2400
         TabIndex        =   16
         Top             =   2160
         Width           =   735
      End
      Begin VB.Label Label9 
         Caption         =   "让步幅度"
         Height          =   375
         Left            =   120
         TabIndex        =   15
         Top             =   2160
         Width           =   735
      End
   End
   Begin VB.CommandButton CmdChange 
      Caption         =   "修改"
      Height          =   495
      Left            =   3720
      TabIndex        =   5
      Top             =   4200
      Width           =   975
   End
   Begin VB.CommandButton CmdCancel 
      Caption         =   "取消"
      Height          =   495
      Left            =   4920
      TabIndex        =   4
      Top             =   4200
      Width           =   975
   End
   Begin VB.CommandButton CmdSellQuery 
      Caption         =   "查询"
      Height          =   495
      Left            =   4680
      TabIndex        =   3
      Top             =   240
      Width           =   1215
   End
   Begin VB.CommandButton CmdAdd 
      Caption         =   "增加"
      Height          =   495
      Left            =   1320
      TabIndex        =   2
      Top             =   4200
      Width           =   975
   End
   Begin VB.CommandButton CmdDelete 
      Caption         =   "删除"
      Height          =   495
      Left            =   2520
      TabIndex        =   1
      Top             =   4200
      Width           =   975
   End
   Begin VB.TextBox Txtsellname 
      Height          =   495
      Left            =   2040
      TabIndex        =   0
      Top             =   240
      Width           =   1575
   End
   Begin VB.Label Label1 
      Caption         =   "请输入用户名"
      Height          =   495
      Left            =   720
      TabIndex        =   23
      Top             =   240
      Width           =   1095
   End
End
Attribute VB_Name = "frmSellerInfomanage"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False

Private Sub CmdAdd_Click()
    Dim RS
    Set RS = CreateObject("ADODB.RecordSet")
    StrSQL = "select * from sellerinfo "
    RS.Open StrSQL, ConnStr, 1, 3
    RS.AddNew
        RS("username") = TxtsellIDSM
        RS("sellname") = TxtcompanySM
        RS("production") = txtProductionSM
        RS("serve") = txtServeSM
        RS("lowprice") = txtLowPriceSM
        RS("highprice") = txtHighpriceSM
        RS("quality") = txtQualitySM
        RS("step") = txtStepSM
    RS.Update
    RS.Close
    Set RS = Nothing
    MsgBox "此项已添加!", vbOKOnly Or vbInformation
    End Sub

Private Sub CmdSellQuery_Click()
    Dim RS
    Set RS = CreateObject("ADODB.RecordSet")
    StrSQL = "select * from sellerinfo where username =  '" & Txtsellname & "'"
    RS.Open StrSQL, ConnStr, 1, 1
    If Not RS.EOF Then
        
        TxtsellIDSM = RS("username")
        TxtcompanySM = RS("sellname")
        txtProductionSM = RS("production")
        txtServeSM = RS("serve")
        txtLowPriceSM = RS("lowprice")
        txtHighpriceSM = RS("highprice")
        txtQualitySM = RS("quality")
        txtStepSM = RS("step")

    ElseIf Txtsellname = "" Then
        MsgBox "请输入用户名!", vbOKOnly Or vbInformation, "卖方信息管理"
       
   Else
        MsgBox "查无此用户名,请添加!", vbOKOnly Or vbInformation, "卖方信息管理"
        TxtsellIDSM = ""
        TxtcompanySM = ""
        txtProductionSM = ""
        txtServeSM = ""
        txtLowPriceSM = ""
        txtHighpriceSM = ""
        txtQualitySM = ""
        txtStepSM = ""
        RS.Close
        Set RS = Nothing
    End If
End Sub

Private Sub cmdCancel_Click()
Me.Hide
End Sub

Private Sub CmdChange_Click()
    Dim RS
    Set RS = CreateObject("ADODB.RecordSet")
    StrSQL = "select * from sellerinfo where username =  '" & Txtsellname & "'"
    RS.Open StrSQL, ConnStr, 1, 3
    If Not RS.EOF Then
        RS("username") = TxtsellIDSM
        RS("sellname") = TxtcompanySM
        RS("production") = txtProductionSM
        RS("serve") = txtServeSM
        RS("lowprice") = txtLowPriceSM
        RS("highprice") = txtHighpriceSM
        RS("quality") = txtQualitySM
        RS("step") = txtStepSM
        RS.Update
        RS.Close
        Set RS = Nothing
        MsgBox "此项已修改!", vbOKOnly Or vbInformation
    Else
        RS.Close
        Set RS = Nothing
        MsgBox "查无此用户名,请添加!", vbOKOnly Or vbInformation
        CmdAdd_Click
    End If
End Sub

Private Sub CmdDelete_Click()
    If MsgBox("是否删除此买家?", vbYesNo Or vbQuestion) = vbYes Then
        Dim RS
        Set RS = CreateObject("ADODB.RecordSet")
        StrSQL = "select * from sellerinfo where username =  '" & TxtsellIDSM & "'"
        RS.Open StrSQL, ConnStr, 1, 3
        If RS.EOF Then
            MsgBox "查无此项!", vbOKOnly
        Else
            RS.Delete
            TxtsellIDSM = ""
            TxtcompanySM = ""
            txtProductionSM = ""
            txtServeSM = ""
            txtLowPriceSM = ""
            txtHighpriceSM = ""
            txtQualitySM = ""
            txtStepSM = ""
            RS.Update
        End If
        RS.Close
        Set RS = Nothing
    End If
End Sub

⌨️ 快捷键说明

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