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

📄 frmcustom.frm

📁 这是用Visual Basic6开发的大型喷绘业务管理系统,数据库采用Access数据库
💻 FRM
字号:
VERSION 5.00
Begin VB.Form frmCUSTOM 
   Caption         =   "客户情况录入"
   ClientHeight    =   5145
   ClientLeft      =   60
   ClientTop       =   345
   ClientWidth     =   4410
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   ScaleHeight     =   5145
   ScaleWidth      =   4410
   StartUpPosition =   3  '窗口缺省
   Begin VB.Frame Frame1 
      Height          =   4995
      Left            =   90
      TabIndex        =   9
      Top             =   30
      Width           =   4185
      Begin VB.CommandButton Command3 
         Height          =   315
         Left            =   1620
         Picture         =   "frmCUSTOM.frx":0000
         Style           =   1  'Graphical
         TabIndex        =   21
         Top             =   4470
         Width           =   975
      End
      Begin VB.TextBox Text8 
         Height          =   315
         Left            =   1500
         TabIndex        =   8
         Top             =   3420
         Width           =   2025
      End
      Begin VB.TextBox Text7 
         Height          =   315
         Left            =   1500
         TabIndex        =   7
         Top             =   3030
         Width           =   2025
      End
      Begin VB.TextBox Text6 
         Height          =   315
         Left            =   1500
         TabIndex        =   6
         Top             =   2640
         Width           =   2025
      End
      Begin VB.TextBox Text5 
         Height          =   315
         Left            =   1500
         TabIndex        =   5
         Top             =   2250
         Width           =   2025
      End
      Begin VB.TextBox Text4 
         Height          =   315
         Left            =   1500
         TabIndex        =   4
         Top             =   1860
         Width           =   2025
      End
      Begin VB.TextBox Text3 
         Height          =   315
         Left            =   1500
         TabIndex        =   3
         Top             =   1470
         Width           =   2025
      End
      Begin VB.TextBox Text2 
         Height          =   315
         Left            =   1500
         TabIndex        =   2
         Top             =   1080
         Width           =   1155
      End
      Begin VB.TextBox Text1 
         Height          =   315
         Left            =   1500
         TabIndex        =   1
         Top             =   690
         Width           =   2025
      End
      Begin VB.ComboBox Combo1 
         Height          =   300
         Left            =   1500
         TabIndex        =   0
         Top             =   330
         Width           =   1395
      End
      Begin VB.CommandButton Command2 
         Height          =   315
         Left            =   2820
         Picture         =   "frmCUSTOM.frx":0296
         Style           =   1  'Graphical
         TabIndex        =   11
         Top             =   4470
         Width           =   945
      End
      Begin VB.CommandButton Command1 
         Height          =   315
         Left            =   450
         Picture         =   "frmCUSTOM.frx":052C
         Style           =   1  'Graphical
         TabIndex        =   10
         Top             =   4470
         Width           =   975
      End
      Begin VB.Label Label1 
         Caption         =   "银行帐号"
         Height          =   285
         Index           =   8
         Left            =   690
         TabIndex        =   20
         Top             =   3480
         Width           =   885
      End
      Begin VB.Label Label1 
         Caption         =   "网    址"
         Height          =   285
         Index           =   7
         Left            =   690
         TabIndex        =   19
         Top             =   3090
         Width           =   885
      End
      Begin VB.Label Label1 
         Caption         =   "电子邮件"
         Height          =   285
         Index           =   6
         Left            =   690
         TabIndex        =   18
         Top             =   2670
         Width           =   885
      End
      Begin VB.Label Label1 
         Caption         =   "地    址"
         Height          =   285
         Index           =   5
         Left            =   690
         TabIndex        =   17
         Top             =   2310
         Width           =   885
      End
      Begin VB.Label Label1 
         Caption         =   "传    真"
         Height          =   285
         Index           =   4
         Left            =   690
         TabIndex        =   16
         Top             =   1920
         Width           =   885
      End
      Begin VB.Label Label1 
         Caption         =   "联系电话"
         Height          =   285
         Index           =   3
         Left            =   690
         TabIndex        =   15
         Top             =   1530
         Width           =   885
      End
      Begin VB.Label Label1 
         Caption         =   "联 系 人"
         Height          =   285
         Index           =   2
         Left            =   690
         TabIndex        =   14
         Top             =   1140
         Width           =   885
      End
      Begin VB.Label Label1 
         Caption         =   "客户名称 "
         Height          =   285
         Index           =   1
         Left            =   660
         TabIndex        =   13
         Top             =   750
         Width           =   885
      End
      Begin VB.Label Label1 
         Caption         =   "客户类别"
         Height          =   285
         Index           =   0
         Left            =   660
         TabIndex        =   12
         Top             =   390
         Width           =   885
      End
   End
End
Attribute VB_Name = "frmCUSTOM"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Dim env As rdoEnvironment
Dim cn As rdoConnection
Dim result As rdoResultset
Dim result1 As rdoResultset
Dim d_conn, sql As String
Dim hrowcount, hrowcount1 As Integer
Private Sub Combo1_KeyPress(KeyAscii As Integer)
    If KeyAscii = 13 Then
       KeyAscii = 0
       SendKeys "{tab}"
    End If
End Sub

Private Sub Command1_Click()
    If MsgBox("确定是否存盘?", 36, "存盘!!") = 6 Then
       sql = "insert into  CustomTable(客户类别,客户名称,联系人,联系电话,传真,地址,电子邮件,网址,银行帐号)  values('" & Trim(Combo1.Text) & "','" & Trim(Text1.Text) & "','" & Trim(Text2.Text) & "','" & Trim(Text3.Text) & "','" & Trim(Text4.Text) & "','" & Trim(Text5.Text) & "','" & Trim(Text6.Text) & "','" & Trim(Text7.Text) & "','" & Trim(Text8.Text) & "')"
       Set result = cn.OpenResultset(sql, rdOpenDynamic, rdConcurRowVer)
       MsgBox "存盘结束!!"
    End If
End Sub

Private Sub Command2_Click()
   Unload Me
End Sub

Private Sub Command3_Click()
   frmPHcustBrow.Show 1
End Sub

Private Sub Form_Load()
    Move Screen.Width / 2 - frmCUSTOM.Width / 2, Screen.Height / 2 - frmCUSTOM.Height / 2
    Set env = rdoEnvironments(0)
    env.CursorDriver = rdUseOdbc
    d_conn = "uid=sa;pwd=;driver={SQL SERVER};SERVER=ntserver;database=phdatabase;"
    Set cn = env.OpenConnection(dsname:="odbc_api_demo", Prompt:="rdodriverprompt", ReadOnly:=False, Connect:=d_conn)
End Sub

Private Sub Text1_KeyPress(KeyAscii As Integer)
    If KeyAscii = 13 Then
       KeyAscii = 0
       SendKeys "{tab}"
    End If
End Sub

Private Sub Text2_KeyPress(KeyAscii As Integer)
    If KeyAscii = 13 Then
       KeyAscii = 0
       SendKeys "{tab}"
    End If
End Sub

Private Sub Text3_KeyPress(KeyAscii As Integer)
    If KeyAscii = 13 Then
       KeyAscii = 0
       SendKeys "{tab}"
    End If
End Sub

Private Sub Text4_KeyPress(KeyAscii As Integer)
    If KeyAscii = 13 Then
       KeyAscii = 0
       SendKeys "{tab}"
    End If
End Sub

Private Sub Text5_KeyPress(KeyAscii As Integer)
    If KeyAscii = 13 Then
       KeyAscii = 0
       SendKeys "{tab}"
    End If
End Sub

Private Sub Text6_KeyPress(KeyAscii As Integer)
    If KeyAscii = 13 Then
       KeyAscii = 0
       SendKeys "{tab}"
    End If
End Sub

Private Sub Text7_KeyPress(KeyAscii As Integer)
    If KeyAscii = 13 Then
       KeyAscii = 0
       SendKeys "{tab}"
    End If
End Sub

Private Sub Text8_KeyPress(KeyAscii As Integer)
    If KeyAscii = 13 Then
       KeyAscii = 0
       SendKeys "{tab}"
    End If
End Sub

⌨️ 快捷键说明

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