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

📄 wd.frm

📁 小软件,是一个光盘发行的销售管理软件,第一次上这个网站,先测试一下,如果觉得可以,以后肯定多多的发,
💻 FRM
字号:
VERSION 5.00
Begin VB.Form wd 
   BorderStyle     =   1  'Fixed Single
   Caption         =   "网点编辑"
   ClientHeight    =   5235
   ClientLeft      =   45
   ClientTop       =   375
   ClientWidth     =   7845
   BeginProperty Font 
      Name            =   "宋体"
      Size            =   12
      Charset         =   134
      Weight          =   400
      Underline       =   0   'False
      Italic          =   0   'False
      Strikethrough   =   0   'False
   EndProperty
   Icon            =   "wd.frx":0000
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MinButton       =   0   'False
   ScaleHeight     =   5235
   ScaleWidth      =   7845
   StartUpPosition =   2  '屏幕中心
   Begin VB.CommandButton Command4 
      Caption         =   "修改"
      Height          =   495
      Left            =   5235
      TabIndex        =   14
      Top             =   4440
      Width           =   1215
   End
   Begin VB.CommandButton Command3 
      Caption         =   "保存"
      Height          =   495
      Left            =   3435
      TabIndex        =   13
      Top             =   4440
      Width           =   1215
   End
   Begin VB.CommandButton Command1 
      Caption         =   "查找"
      Height          =   495
      Left            =   1395
      TabIndex        =   12
      Top             =   4440
      Width           =   1335
   End
   Begin VB.TextBox Text6 
      Height          =   1215
      Left            =   2160
      TabIndex        =   5
      Text            =   "Text6"
      Top             =   2760
      Width           =   4815
   End
   Begin VB.TextBox Text5 
      Height          =   360
      Left            =   2160
      TabIndex        =   4
      Text            =   "Text5"
      Top             =   2280
      Width           =   4815
   End
   Begin VB.TextBox Text4 
      Height          =   375
      Left            =   2160
      TabIndex        =   3
      Text            =   "Text4"
      Top             =   1800
      Width           =   4335
   End
   Begin VB.TextBox Text3 
      Height          =   375
      Left            =   2160
      TabIndex        =   2
      Text            =   "Text3"
      Top             =   1320
      Width           =   2055
   End
   Begin VB.TextBox Text2 
      Height          =   375
      Left            =   2160
      TabIndex        =   1
      Text            =   "Text2"
      Top             =   840
      Width           =   4815
   End
   Begin VB.TextBox Text1 
      Height          =   360
      Left            =   2160
      TabIndex        =   0
      Text            =   "Text1"
      Top             =   360
      Width           =   1095
   End
   Begin VB.Label Label7 
      Caption         =   "Label7"
      ForeColor       =   &H000000FF&
      Height          =   375
      Left            =   3840
      TabIndex        =   15
      Top             =   240
      Width           =   3735
   End
   Begin VB.Label Label6 
      Caption         =   "服务方式:"
      Height          =   255
      Left            =   720
      TabIndex        =   11
      Top             =   2760
      Width           =   1335
   End
   Begin VB.Label Label5 
      Caption         =   "联系方式:"
      Height          =   255
      Left            =   720
      TabIndex        =   10
      Top             =   1800
      Width           =   1455
   End
   Begin VB.Label Label4 
      Caption         =   "联系人:"
      Height          =   255
      Left            =   720
      TabIndex        =   9
      Top             =   1320
      Width           =   1095
   End
   Begin VB.Label Label3 
      Caption         =   "销售商地址:"
      Height          =   255
      Left            =   720
      TabIndex        =   8
      Top             =   2280
      Width           =   1455
   End
   Begin VB.Label Label2 
      Caption         =   "销售商名称:"
      Height          =   255
      Left            =   720
      TabIndex        =   7
      Top             =   840
      Width           =   1455
   End
   Begin VB.Label Label1 
      Caption         =   "网点编号:"
      Height          =   255
      Left            =   720
      TabIndex        =   6
      Top             =   360
      Width           =   1215
   End
End
Attribute VB_Name = "wd"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command2_Click()


End Sub

Private Sub Command1_Click()
Dim reslut As New ADODB.Recordset
If Text1.Text = "" Then
   MsgBox "销售网点编号不能为空,请检查!", vbOKOnly + vbInformation, "互联网出版发行中心发行系统!"
   Exit Sub
End If
'i = Text1.Text
reslut.Open "select * from 销售网点资料 ", main.strcnn, adOpenKeyset, adLockOptimistic
If Not reslut.EOF Then
   For i = 1 To reslut.RecordCount
       If reslut.Fields("销售商ID") = CInt(Text1.Text) Then
          If IsNull(reslut.Fields("销售商名称")) = False Then
             Text2.Text = reslut.Fields("销售商名称")
          End If
          If IsNull(reslut.Fields("联系人姓名")) = False Then
             Text3.Text = reslut.Fields("联系人姓名")
          End If
          If IsNull(reslut.Fields("工作电话")) = False Then
             Text4.Text = reslut.Fields("工作电话")
          End If
          If IsNull(reslut.Fields("地址")) = False Then
             Text5.Text = reslut.Fields("地址")
          End If
          If IsNull(reslut.Fields("移动电话")) = False Then
             Text6.Text = reslut.Fields("移动电话")
          End If
          Command3.Enabled = False
          Text1.Enabled = False
          Exit For
       End If
   reslut.MoveNext
   Next i
Else
   MsgBox "查询的编号不存在,请检查!", vbOKOnly + vbInformation, "互联网出版发行中心发行系统!"
   Text1.Text = ""
   Text1.SetFocus
End If
reslut.Close
End Sub

Private Sub Command3_Click()
Dim reslut As New ADODB.Recordset
Dim i
i = MsgBox("确定输入该销售网点资料?", vbYesNo + vbInformation, "互联网出版发行中心发行系统!")
If i = vbYes Then
   reslut.Open "销售网点资料", main.strcnn, adOpenKeyset, adLockOptimistic
   reslut.AddNew
   reslut.Fields("销售商名称") = Text2.Text
   reslut.Fields("联系人姓名") = Text3.Text
   reslut.Fields("工作电话") = Text4.Text
   reslut.Fields("地址") = Text5.Text
   reslut.Fields("移动电话") = Text6.Text
   reslut.Update
   reslut.Close
   MsgBox "信息保存完成!", vbOKOnly + vbInformation, "互联网出版发行中心发行系统!"
   Call Form_Load
End If
End Sub

Private Sub Command4_Click()
Dim reslut As New ADODB.Recordset
Dim i
reslut.Open "select * from 销售网点资料 ", main.strcnn, adOpenKeyset, adLockOptimistic
If Not reslut.EOF Then
   For i = 1 To reslut.RecordCount
       If reslut.Fields("销售商ID") = CInt(Text1.Text) Then
          reslut.Fields("销售商名称") = Text2.Text
          reslut.Fields("联系人姓名") = Text3.Text
          reslut.Fields("工作电话") = Text4.Text
          reslut.Fields("地址") = Text5.Text
          reslut.Fields("移动电话") = Text6.Text
          reslut.Update
          Command3.Enabled = True
          Text1.Enabled = True
          MsgBox "销售网点资料修改完成!", vbOKOnly + vbInformation, "互联网出版发行中心发行系统!"
       End If
   reslut.MoveNext
   Next i
End If
reslut.Close
Call Form_Load

End Sub

Private Sub Form_Load()
Dim reslut As New ADODB.Recordset
Text1.Text = ""
Text2.Text = ""
Text3.Text = ""
Text4.Text = ""
Text5.Text = ""
Text6.Text = ""
Label7.Caption = ""
reslut.Open "select 销售商ID FROM 销售网点资料", main.strcnn, adOpenKeyset, adLockOptimistic
If Not reslut.EOF Then
   Label7.Caption = "本系统现有" & reslut.RecordCount & "个销售网点资料!"
Else
   Label7.Caption = "本系统内没有销售网点资料!"
End If
reslut.Close
End Sub

⌨️ 快捷键说明

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