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

📄 superinrtendentform.frm

📁 即时通讯
💻 FRM
📖 第 1 页 / 共 2 页
字号:
         Width           =   975
      End
      Begin VB.Label Label1 
         Caption         =   "个人开户:"
         Height          =   255
         Index           =   10
         Left            =   3960
         TabIndex        =   11
         Top             =   840
         Width           =   975
      End
      Begin VB.Label Label1 
         Caption         =   "个人邮箱:"
         Height          =   255
         Index           =   9
         Left            =   3960
         TabIndex        =   10
         Top             =   360
         Width           =   975
      End
      Begin VB.Label Label1 
         AutoSize        =   -1  'True
         Caption         =   "个人网址:"
         Height          =   180
         Index           =   8
         Left            =   360
         TabIndex        =   9
         Top             =   4200
         Width           =   900
      End
      Begin VB.Label Label1 
         AutoSize        =   -1  'True
         Caption         =   "手    机:"
         Height          =   180
         Index           =   7
         Left            =   360
         TabIndex        =   8
         Top             =   3720
         Width           =   900
      End
      Begin VB.Label Label1 
         AutoSize        =   -1  'True
         Caption         =   "业务传真:"
         Height          =   180
         Index           =   6
         Left            =   360
         TabIndex        =   7
         Top             =   3240
         Width           =   900
      End
      Begin VB.Label Label1 
         AutoSize        =   -1  'True
         Caption         =   "业务电话:"
         Height          =   180
         Index           =   5
         Left            =   360
         TabIndex        =   6
         Top             =   2760
         Width           =   900
      End
      Begin VB.Label Label1 
         AutoSize        =   -1  'True
         Caption         =   "联系人称呼:"
         Height          =   180
         Index           =   4
         Left            =   180
         TabIndex        =   5
         Top             =   2280
         Width           =   1080
      End
      Begin VB.Label Label1 
         AutoSize        =   -1  'True
         Caption         =   "部    门:"
         Height          =   180
         Index           =   3
         Left            =   360
         TabIndex        =   4
         Top             =   1800
         Width           =   900
      End
      Begin VB.Label Label1 
         AutoSize        =   -1  'True
         Caption         =   "性    别:"
         Height          =   180
         Index           =   2
         Left            =   360
         TabIndex        =   3
         Top             =   1320
         Width           =   900
      End
      Begin VB.Label Label1 
         AutoSize        =   -1  'True
         Caption         =   "联系人姓名:"
         Height          =   180
         Index           =   1
         Left            =   180
         TabIndex        =   2
         Top             =   840
         Width           =   1080
      End
      Begin VB.Label Label1 
         AutoSize        =   -1  'True
         Caption         =   "供 应 商:"
         Height          =   180
         Index           =   0
         Left            =   360
         TabIndex        =   1
         Top             =   360
         Width           =   900
      End
   End
End
Attribute VB_Name = "superinrtendentform"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
'**************************************
'*    模 块 名 称 :联系列表用户操作界面
'*    功 能 描 述 :联系列表用户操作界面
'*    程序员姓名  : 石春晓
'*    最后修改人  : 石春晓
'*    最后修改时间:2005/09/23
'**************************************
Option Explicit
Public m_operatorType As Integer       ' 操作类型 0 - 新增 1 - 修改
Public m_supplierid  As String         ' 修改时其它窗体传递过来的参数
Public superinrtendentid  As String    ' 修改时其它窗体传递过来的参数
Private m_supplierDAO As supplierDAO   ' 数据库操作类
Private m_recordset As ADODB.Recordset ' 数据操作数据集对象
Public m_suppliername As String         '供应商名称
Public f As String


Private Sub c_cancel_Click()
    Unload Me
End Sub

Private Sub c_new_Click()
    Call Check
    If m_operatorType = 1 Then
        If f = "0" Then
           Exit Sub
        Else
           Call Newsuperinrtendent
           Call clear
        End If
    ElseIf m_operatorType = 0 Then
        If f = "0" Then
           Exit Sub
        Else
               Call modifysuperinrtendent
               Call clear
        End If
    End If
End Sub

Private Sub c_save_Click()
    Call Check
    If m_operatorType = 1 Then
        If f = "0" Then
           Exit Sub
        Else
           Call Newsuperinrtendent
        End If
    ElseIf m_operatorType = 0 Then
        If f = "0" Then
           Exit Sub
        Else
               Call modifysuperinrtendent
        End If
    End If
    Unload Me
End Sub

Private Sub Command3_Click()
        Call Drbmhelp(1, Trim(deliverydate.text))                                   ' 根据设置选择显示编码和名称,并进行存储
    If Len(XT_calendar.Xtfhcs) <> 0 Then
            deliverydate.text = XT_calendar.Xtfhcs                              ' 将日历窗体里取得的值传给建档日期的文本框
    End If
End Sub

Private Sub Form_Load()
    Set m_supplierDAO = New supplierDAO
    Set m_recordset = New ADODB.Recordset
'
'    Me.Height = 6285
'    Me.Width = 7665
    SetToCenter Me
    Combo1.AddItem "男"
    Combo1.AddItem "女"
    Text1(15).text = MainForm.g_application.m_userName
    If m_operatorType = 1 Then
        Me.caption = "联系人_新增"
        
        clear
    Else
        Me.caption = "联系人_修改"
        FindByIdRefresh
    End If
    
End Sub
'**************************************
'*    功 能 描 述 :产品类别数据处理函数
'*    输 入 参 数 :无
'*    输 出 能 数 :无
'**************************************
Private Sub Newsuperinrtendent()
    '
    Dim ret As Boolean
    Dim d1 As String
    Dim d2 As String
    d1 = CDate(Trim(deliverydate.text))
    d2 = CDate(Trim(Text1(2).text))
    ret = m_supplierDAO.Newsuperinrtendent(m_recordset, Trim(m_supplierid), Trim(Text1(1).text), Trim(Combo1.text), _
                   Trim(Text1(3).text), Trim(Text1(4).text), Trim(Text1(5).text), Trim(Text1(6).text), Trim(Text1(7).text), _
                   Trim(Text1(8).text), Trim(Text1(9).text), Trim(Text1(10).text), Trim(Text1(11).text), Trim(Text1(12).text), _
                   Trim(Text1(13).text), Trim(d1), Trim(Text1(15).text), Trim(d2), Trim(Text1(17).text))
End Sub
'**************************************
'*    功 能 描 述 :修改产品类别处理函数
'*    输 入 参 数 :无
'*    输 出 能 数 :无
'**************************************
Private Sub modifysuperinrtendent()
    '
    Dim ret As Boolean
    Dim d1 As String
    Dim d2 As String
    d1 = CDate(Trim(deliverydate.text))
    d2 = CDate(Trim(Text1(2).text))
    ret = m_supplierDAO.modifysuperinrtendent(m_recordset, Trim(superinrtendentid), Trim(m_supplierid), Trim(Text1(1).text), Trim(Combo1.text), _
                   Trim(Text1(3).text), Trim(Text1(4).text), Trim(Text1(5).text), Trim(Text1(6).text), Trim(Text1(7).text), _
                   Trim(Text1(8).text), Trim(Text1(9).text), Trim(Text1(10).text), Trim(Text1(11).text), Trim(Text1(12).text), _
                   Trim(Text1(13).text), Trim(d1), Trim(Text1(15).text), Trim(d2), Trim(Text1(17).text))
End Sub
'**************************************
'*    功 能 描 述 :检验数据的合法性
'*    输 入 参 数 :无
'*    输 出 能 数 :无
'**************************************
Private Sub Check()
    f = "1"
    If Trim(Text1(1).text) = "" Then
        MainForm.g_msgText = "联系人姓名不能为空!"
        HMsgBox MainForm.g_msgText, 0, 1
        Text1(1).SetFocus
        f = "0"
        Exit Sub
        
    End If
      
End Sub
'**************************************
'*    功 能 描 述 :根据联系ID找到联系记录并显示在界面上
'*    输 入 参 数 :无
'*    输 出 能 数 :无
'**************************************
Private Sub FindByIdRefresh()
    Dim ret As Boolean
    
    ret = m_supplierDAO.Findsuperinrtendentid(m_recordset, Trim(superinrtendentid))
    
    If ret Then
      With m_recordset
            Text1(0).text = Trim(.Fields(2))
            Text2.text = Trim(m_suppliername)
            Text1(1).text = Trim(.Fields(3))
            Combo1.text = Trim(.Fields(4))
            Text1(3).text = Trim(.Fields(5))
            Text1(4).text = Trim(.Fields(6))
            Text1(5).text = Trim(.Fields(7))
            Text1(6).text = Trim(.Fields(8))
            Text1(7).text = Trim(.Fields(9))
            Text1(8).text = Trim(.Fields(10))
            Text1(9).text = Trim(.Fields(11))
            Text1(10).text = Trim(.Fields(12))
            Text1(11).text = Trim(.Fields(13))
            Text1(12).text = Trim(.Fields(14))
            Text1(13).text = Trim(.Fields(15))
            deliverydate.text = Trim(.Fields(16))
            Text1(15).text = Trim(.Fields(17))
            Text1(2).text = Trim(.Fields(18))
            Text1(17).text = Trim(.Fields(19))
            m_recordset.Close
      End With
    Else
        MainForm.g_msgText = "联系人ID不正确,请重新操作!"
        HMsgBox MainForm.g_msgText, 0, 1
'        Exit Sub
'        Unload Me
    End If
End Sub
'**************************************
'*    功 能 描 述 :清除界面上文本框里的所有内容
'*    输 入 参 数 :无
'*    输 出 能 数 :无
'**************************************
Private Sub clear()
            Text2.text = m_suppliername
            Combo1.text = ""
            Text1(1).text = ""
            Text1(3).text = ""
            Text1(4).text = ""
            Text1(5).text = ""
            Text1(6).text = ""
            Text1(7).text = ""
            Text1(8).text = ""
            Text1(9).text = ""
            Text1(10).text = ""
            Text1(11).text = ""
            Text1(12).text = ""
            Text1(13).text = ""
            Text1(15).text = Trim(MainForm.g_application.m_userName)
            Text1(17).text = ""
            deliverydate.text = Date
            Text1(2).text = Date
End Sub

Public Sub Drbmhelp(bzlx As Integer, Scdwnr As String)                          '调入编码参照窗体
    
    '函数参数:帮助类型(0-通用型 1-日期型 2-特殊型),帮助编码,首次定位内容
    On Error GoTo ErrHandle
    XT_calendar.Xtfhcs = ""
    Select Case bzlx
        Case 1
            XT_calendar.xtcdcs = Date
            XT_calendar.show 1      '显示日历窗体
           
    End Select
    
ErrHandle:

End Sub

⌨️ 快捷键说明

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