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

📄 frmuserinfo.frm

📁 用VB6.0编写的QQ聊天软件
💻 FRM
字号:
VERSION 5.00
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "mscomctl.ocx"
Begin VB.Form frmUserInfo 
   BorderStyle     =   1  'Fixed Single
   Caption         =   "用户信息"
   ClientHeight    =   3495
   ClientLeft      =   45
   ClientTop       =   330
   ClientWidth     =   4215
   BeginProperty Font 
      Name            =   "宋体"
      Size            =   9
      Charset         =   134
      Weight          =   400
      Underline       =   0   'False
      Italic          =   0   'False
      Strikethrough   =   0   'False
   EndProperty
   Icon            =   "frmUserInfo.frx":0000
   LockControls    =   -1  'True
   MaxButton       =   0   'False
   ScaleHeight     =   233
   ScaleMode       =   3  'Pixel
   ScaleWidth      =   281
   StartUpPosition =   2  'CenterScreen
   Begin VB.Frame fra 
      Height          =   2775
      Index           =   0
      Left            =   1080
      TabIndex        =   23
      Top             =   480
      Width           =   2895
      Begin VB.TextBox txtName 
         CausesValidation=   0   'False
         Height          =   270
         Left            =   960
         Locked          =   -1  'True
         MaxLength       =   16
         TabIndex        =   4
         Top             =   600
         Width           =   1815
      End
      Begin VB.TextBox txtUserID 
         CausesValidation=   0   'False
         Height          =   270
         Left            =   960
         Locked          =   -1  'True
         MaxLength       =   16
         TabIndex        =   2
         Top             =   240
         Width           =   1815
      End
      Begin VB.TextBox txtSex 
         Alignment       =   2  'Center
         CausesValidation=   0   'False
         Height          =   270
         Left            =   960
         Locked          =   -1  'True
         MaxLength       =   2
         TabIndex        =   8
         Top             =   1320
         Width           =   495
      End
      Begin VB.TextBox txtProvince 
         Height          =   270
         Left            =   960
         Locked          =   -1  'True
         MaxLength       =   16
         TabIndex        =   12
         Top             =   1680
         Width           =   1815
      End
      Begin VB.TextBox txtCity 
         Height          =   270
         Left            =   960
         Locked          =   -1  'True
         MaxLength       =   16
         TabIndex        =   14
         Top             =   2040
         Width           =   1815
      End
      Begin VB.TextBox txtPhone 
         CausesValidation=   0   'False
         Height          =   270
         IMEMode         =   3  'DISABLE
         Left            =   960
         Locked          =   -1  'True
         MaxLength       =   16
         TabIndex        =   16
         Top             =   2400
         Width           =   1815
      End
      Begin VB.TextBox txtRealName 
         Height          =   270
         Left            =   960
         Locked          =   -1  'True
         MaxLength       =   10
         TabIndex        =   6
         Top             =   960
         Width           =   1815
      End
      Begin VB.TextBox txtAge 
         Alignment       =   2  'Center
         CausesValidation=   0   'False
         Height          =   270
         IMEMode         =   3  'DISABLE
         Left            =   2280
         Locked          =   -1  'True
         MaxLength       =   3
         TabIndex        =   10
         Top             =   1320
         Width           =   495
      End
      Begin VB.Label lbl 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "昵称(&M)"
         Height          =   180
         Index           =   1
         Left            =   240
         TabIndex        =   3
         Top             =   645
         Width           =   630
      End
      Begin VB.Label lbl 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "标识(&I)"
         Height          =   180
         Index           =   0
         Left            =   240
         TabIndex        =   1
         Top             =   285
         Width           =   630
      End
      Begin VB.Label lbl 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "电话(&H)"
         Height          =   180
         Index           =   7
         Left            =   240
         TabIndex        =   15
         Top             =   2445
         Width           =   630
      End
      Begin VB.Label lbl 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "城市(&C)"
         Height          =   180
         Index           =   6
         Left            =   240
         TabIndex        =   13
         Top             =   2085
         Width           =   630
      End
      Begin VB.Label lbl 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "省份(&P)"
         Height          =   180
         Index           =   5
         Left            =   240
         TabIndex        =   11
         Top             =   1725
         Width           =   630
      End
      Begin VB.Label lbl 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "姓名(&N)"
         Height          =   180
         Index           =   3
         Left            =   240
         TabIndex        =   5
         Top             =   1005
         Width           =   630
      End
      Begin VB.Label lbl 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "性别(&S)"
         Height          =   180
         Index           =   2
         Left            =   240
         TabIndex        =   7
         Top             =   1365
         Width           =   630
      End
      Begin VB.Label lbl 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "年龄(&A)"
         Height          =   180
         Index           =   4
         Left            =   1560
         TabIndex        =   9
         Top             =   1365
         Width           =   630
      End
   End
   Begin VB.PictureBox picUser 
      AutoRedraw      =   -1  'True
      BorderStyle     =   0  'None
      Height          =   480
      Left            =   360
      ScaleHeight     =   32
      ScaleMode       =   3  'Pixel
      ScaleWidth      =   32
      TabIndex        =   22
      TabStop         =   0   'False
      Top             =   600
      Width           =   480
   End
   Begin VB.CommandButton cmdClose 
      Cancel          =   -1  'True
      Caption         =   "关闭"
      Height          =   375
      Left            =   240
      TabIndex        =   21
      Top             =   2880
      Width           =   735
   End
   Begin VB.Frame fra 
      Height          =   2775
      Index           =   1
      Left            =   1080
      TabIndex        =   24
      Top             =   480
      Visible         =   0   'False
      Width           =   2895
      Begin VB.TextBox txtEmail 
         Height          =   270
         Left            =   120
         Locked          =   -1  'True
         MaxLength       =   60
         TabIndex        =   18
         Top             =   480
         Width           =   2655
      End
      Begin VB.TextBox txtShow 
         CausesValidation=   0   'False
         Height          =   1455
         Left            =   120
         Locked          =   -1  'True
         MaxLength       =   255
         MultiLine       =   -1  'True
         ScrollBars      =   3  'Both
         TabIndex        =   20
         Top             =   1200
         Width           =   2655
      End
      Begin VB.Label lbl 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "个人说明(&S)"
         Height          =   180
         Index           =   9
         Left            =   240
         TabIndex        =   19
         Top             =   960
         Width           =   990
      End
      Begin VB.Label lbl 
         AutoSize        =   -1  'True
         BackStyle       =   0  'Transparent
         Caption         =   "邮箱(&E)"
         Height          =   180
         Index           =   8
         Left            =   240
         TabIndex        =   17
         Top             =   240
         Width           =   630
      End
   End
   Begin MSComctlLib.TabStrip tabUser 
      Height          =   3255
      Left            =   120
      TabIndex        =   0
      Top             =   120
      Width           =   3975
      _ExtentX        =   7011
      _ExtentY        =   5741
      MultiRow        =   -1  'True
      TabMinWidth     =   0
      TabStyle        =   1
      _Version        =   393216
      BeginProperty Tabs {1EFB6598-857C-11D1-B16A-00C0F0283628} 
         NumTabs         =   2
         BeginProperty Tab1 {1EFB659A-857C-11D1-B16A-00C0F0283628} 
            Caption         =   "基本资料"
            Key             =   "Basic"
            Object.ToolTipText     =   "基本资料"
            ImageVarType    =   2
         EndProperty
         BeginProperty Tab2 {1EFB659A-857C-11D1-B16A-00C0F0283628} 
            Caption         =   "其它资料"
            Key             =   "Other"
            Object.ToolTipText     =   "其它资料"
            ImageVarType    =   2
         EndProperty
      EndProperty
   End
End
Attribute VB_Name = "frmUserInfo"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit

Private Sub cmdClose_Click()
    Unload Me
End Sub

Private Sub Form_Load()
    Me.Icon = frmMain.imgLstTools.ListImages(5).Picture
    RefreshUser
    tkNoPopup = True
End Sub

Private Sub Form_Unload(Cancel As Integer)
    tkUserID = ""
    tkNoPopup = False
End Sub

Private Sub RefreshUser()
    On Error Resume Next
    If frmMain.tbTools.Buttons("管理员").Value = tbrPressed And tkViewFriend = False Then
        If rstTemp.State = adStateOpen Then rstTemp.Close
        rstTemp.Open "SELECT 昵称,头像,性别 FROM 管理员 WHERE 标识='" & tkUserID & "'", cnn, adOpenKeyset, adLockReadOnly
        If rst.State = adStateOpen Then rst.Close
        rst.Open "SELECT * FROM 管理员资料 WHERE 标识='" & tkUserID & "'", cnn, adOpenKeyset, adLockReadOnly
    Else
        If rstTemp.State = adStateOpen Then rstTemp.Close
        rstTemp.Open "SELECT 昵称,头像,性别 FROM 用户 WHERE 标识='" & tkUserID & "'", cnn, adOpenKeyset, adLockReadOnly
        If rst.State = adStateOpen Then rst.Close
        rst.Open "SELECT * FROM 用户资料 WHERE 标识='" & tkUserID & "'", cnn, adOpenKeyset, adLockReadOnly
    End If
    frmMain.imgLstFaces.ListImages(Val(rstTemp!头像)).Draw picUser.hdc, 0, 0, 1
    txtUserID.Text = tkUserID
    txtName.Text = rstTemp!昵称
    txtSex.Text = rstTemp!性别
    txtRealName.Text = rst!姓名 & ""
    txtAge.Text = rst!年龄 & ""
    txtProvince.Text = rst!省份 & ""
    txtCity.Text = rst!城市 & ""
    txtPhone.Text = rst!电话 & ""
    txtEmail.Text = rst!邮箱 & ""
    txtShow.Text = rst!说明 & ""
End Sub

Private Sub tabUser_Click()
    If tabUser.Tabs("Basic").Selected = True Then
        fra(0).Visible = True
        fra(1).Visible = False
    ElseIf tabUser.Tabs("Other").Selected = True Then
        fra(1).Visible = True
        fra(0).Visible = False
    End If
End Sub

⌨️ 快捷键说明

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