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

📄 frmcompanyedit.frm

📁 主要实现5个大的功能模块:基本信息的管理、客户会员管理、常业务管理、系统用户管理、系统帮助信息。每个模块有分成多详细的功能子模块
💻 FRM
字号:
VERSION 5.00
Begin VB.Form FrmCompanyEdit 
   BorderStyle     =   1  'Fixed Single
   Caption         =   "编辑公司信息"
   ClientHeight    =   4695
   ClientLeft      =   45
   ClientTop       =   330
   ClientWidth     =   7545
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MinButton       =   0   'False
   Picture         =   "FrmCompanyEdit.frx":0000
   ScaleHeight     =   4695
   ScaleWidth      =   7545
   StartUpPosition =   2  '屏幕中心
   Begin VB.CommandButton Cmd_OK 
      Caption         =   "确 定"
      Height          =   400
      Left            =   1800
      MouseIcon       =   "FrmCompanyEdit.frx":E2C4
      MousePointer    =   99  'Custom
      Style           =   1  'Graphical
      TabIndex        =   3
      Top             =   4080
      Width           =   1000
   End
   Begin VB.CommandButton Cmd_Cancel 
      Cancel          =   -1  'True
      Caption         =   "取 消"
      Height          =   400
      Left            =   4320
      MouseIcon       =   "FrmCompanyEdit.frx":E5CE
      MousePointer    =   99  'Custom
      Style           =   1  'Graphical
      TabIndex        =   4
      Top             =   4080
      Width           =   1000
   End
   Begin VB.Frame Frame1 
      Height          =   3495
      Left            =   240
      TabIndex        =   5
      Top             =   360
      Width           =   6735
      Begin VB.TextBox txtComment 
         Height          =   735
         Left            =   1320
         MultiLine       =   -1  'True
         TabIndex        =   18
         Top             =   2520
         Width           =   4935
      End
      Begin VB.TextBox txtFax 
         Height          =   330
         Left            =   4440
         TabIndex        =   16
         Top             =   885
         Width           =   1815
      End
      Begin VB.TextBox txtContact 
         Height          =   330
         Left            =   4440
         TabIndex        =   14
         Top             =   2040
         Width           =   1815
      End
      Begin VB.TextBox txtCompany 
         BeginProperty Font 
            Name            =   "Arial"
            Size            =   9
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   330
         Left            =   1320
         MaxLength       =   100
         TabIndex        =   13
         Top             =   300
         Width           =   1815
      End
      Begin VB.TextBox txtEmail 
         BeginProperty Font 
            Name            =   "Arial"
            Size            =   9
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   330
         Left            =   1320
         MaxLength       =   20
         TabIndex        =   6
         Top             =   2040
         Width           =   1815
      End
      Begin VB.TextBox txtAddress 
         BeginProperty Font 
            Name            =   "Arial"
            Size            =   9
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   330
         Left            =   1320
         MaxLength       =   50
         TabIndex        =   1
         Top             =   1440
         Width           =   1815
      End
      Begin VB.TextBox txtZipCode 
         BeginProperty Font 
            Name            =   "Arial"
            Size            =   9
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   330
         Left            =   4440
         MaxLength       =   20
         TabIndex        =   2
         Top             =   1440
         Width           =   1815
      End
      Begin VB.TextBox txtTelephone 
         BeginProperty Font 
            Name            =   "Arial"
            Size            =   9
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         Height          =   330
         Left            =   1320
         MaxLength       =   100
         TabIndex        =   0
         Top             =   885
         Width           =   1815
      End
      Begin VB.Label lblType 
         Caption         =   "公司"
         Height          =   255
         Left            =   4440
         TabIndex        =   20
         Top             =   360
         Width           =   1095
      End
      Begin VB.Label Label9 
         Caption         =   "公司种类"
         Height          =   180
         Left            =   3600
         TabIndex        =   19
         Top             =   360
         Width           =   720
      End
      Begin VB.Label Label7 
         Caption         =   "备  注"
         Height          =   180
         Left            =   360
         TabIndex        =   17
         Top             =   2520
         Width           =   615
      End
      Begin VB.Label Label5 
         Caption         =   "传  真"
         Height          =   180
         Left            =   3600
         TabIndex        =   15
         Top             =   960
         Width           =   615
      End
      Begin VB.Label Label1 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "公司名称"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   9
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H00000000&
         Height          =   180
         Left            =   360
         TabIndex        =   12
         Top             =   360
         Width           =   720
      End
      Begin VB.Label Label6 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "邮政编码"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   9
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H00000000&
         Height          =   180
         Left            =   3600
         TabIndex        =   11
         Top             =   1500
         Width           =   720
      End
      Begin VB.Label Label4 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "联系地址"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   9
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H00000000&
         Height          =   180
         Left            =   360
         TabIndex        =   10
         Top             =   1500
         Width           =   720
      End
      Begin VB.Label Label8 
         AutoSize        =   -1  'True
         BackColor       =   &H00FFC0C0&
         BackStyle       =   0  'Transparent
         Caption         =   "联系电话"
         Height          =   180
         Left            =   360
         TabIndex        =   9
         Top             =   960
         Width           =   720
      End
      Begin VB.Label Label3 
         BackStyle       =   0  'Transparent
         Caption         =   "电子邮件"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   9
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H00000000&
         Height          =   180
         Left            =   360
         TabIndex        =   8
         Top             =   2100
         Width           =   720
      End
      Begin VB.Label Label2 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "联系人"
         BeginProperty Font 
            Name            =   "宋体"
            Size            =   9
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H00000000&
         Height          =   180
         Left            =   3600
         TabIndex        =   7
         Top             =   2100
         Width           =   540
      End
   End
End
Attribute VB_Name = "FrmCompanyEdit"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Public Modify As Boolean
Public nId As Integer
Public nTid As Integer

Private Sub Cmd_Cancel_Click()
  Unload Me
End Sub

Private Sub Cmd_OK_Click()
  If Len(Trim(txtCompany)) = 0 Then
    MsgBox "请输入公司名称!"
    txtCompany.SetFocus
    Exit Sub
  End If
  If Len(Trim(txtTelephone)) = 0 Then
    MsgBox "请输入联系电话"
    txtTelephone.SetFocus
    Exit Sub
  End If
  With MyCompany
    .Company = MakeStr(txtCompany)
    .Telephone = MakeStr(txtTelephone)
    .Fax = MakeStr(txtFax)
    .Address = MakeStr(txtAddress)
    .Email = MakeStr(txtEmail)
    .Contact = MakeStr(txtContact)
    .ZipCode = MakeStr(txtZipCode)
    .TypeId = nTid
    .Comment = MakeStr(txtComment)
    If Modify = False Then
      .Insert
    Else
      .Update (nId)
    End If
     MsgBox "成功", vbInformation
  End With
  Unload Me
End Sub

⌨️ 快捷键说明

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