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

📄 setdlg.ctl

📁 vb源码之家界面源码,非常详细的说明和代码
💻 CTL
字号:
VERSION 5.00
Begin VB.UserControl SetDlg 
   BackColor       =   &H00D8E9EC&
   ClientHeight    =   5385
   ClientLeft      =   0
   ClientTop       =   0
   ClientWidth     =   8610
   ControlContainer=   -1  'True
   LockControls    =   -1  'True
   ScaleHeight     =   359
   ScaleMode       =   3  'Pixel
   ScaleWidth      =   574
   Begin VB.Image imgFlag 
      Height          =   240
      Index           =   1
      Left            =   2520
      Picture         =   "SetDlg.ctx":0000
      Top             =   4650
      Visible         =   0   'False
      Width           =   240
   End
   Begin VB.Image imgFlag 
      Height          =   240
      Index           =   0
      Left            =   2340
      Picture         =   "SetDlg.ctx":058A
      Top             =   4620
      Visible         =   0   'False
      Width           =   240
   End
   Begin VB.Image imgSelect 
      Height          =   240
      Left            =   210
      Picture         =   "SetDlg.ctx":0B14
      Top             =   270
      Width           =   240
   End
   Begin VB.Label lblSelect 
      BackStyle       =   0  'Transparent
      Caption         =   "关于"
      Height          =   225
      Index           =   0
      Left            =   450
      TabIndex        =   0
      Top             =   300
      Width           =   1335
   End
   Begin VB.Label lblInfo 
      BackStyle       =   0  'Transparent
      Caption         =   "叶帆软件系列"
      BeginProperty Font 
         Name            =   "宋体"
         Size            =   10.5
         Charset         =   134
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H00FFFFFF&
      Height          =   225
      Left            =   2130
      TabIndex        =   1
      Top             =   270
      Width           =   6525
   End
   Begin VB.Image imgBar 
      Height          =   300
      Left            =   2040
      Picture         =   "SetDlg.ctx":109E
      Stretch         =   -1  'True
      Top             =   210
      Width           =   6315
   End
   Begin VB.Line Line1 
      BorderColor     =   &H00C0C0C0&
      X1              =   136
      X2              =   560
      Y1              =   37
      Y2              =   37
   End
   Begin VB.Shape Shape2 
      BorderColor     =   &H00C0C0C0&
      FillColor       =   &H00FFFFFF&
      FillStyle       =   0  'Solid
      Height          =   5085
      Left            =   1980
      Top             =   150
      Width           =   6495
   End
   Begin VB.Shape shpMenu 
      BorderColor     =   &H00C56A31&
      FillColor       =   &H00D2C3B4&
      FillStyle       =   0  'Solid
      Height          =   375
      Left            =   210
      Top             =   210
      Width           =   1575
   End
   Begin VB.Line linBar 
      BorderColor     =   &H00E0E0E0&
      Index           =   0
      X1              =   30
      X2              =   115
      Y1              =   38
      Y2              =   38
   End
   Begin VB.Shape shpBar1 
      BorderColor     =   &H00C0C0C0&
      FillColor       =   &H00FFFFFF&
      FillStyle       =   0  'Solid
      Height          =   5085
      Left            =   150
      Top             =   150
      Width           =   1695
   End
End
Attribute VB_Name = "SetDlg"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = True
Attribute VB_PredeclaredId = False
Attribute VB_Exposed = False
'*************************************************************************
'**模 块 名:SetDlg
'**说    明:YFsoft 版权所有2005 - 2006(C)
'**创 建 人:叶帆
'**日    期:2005-11-09 15:59:31
'**修 改 人:
'**日    期:
'**描    述:配置对话框
'**版    本:V1.0.0
'*************************************************************************
Option Explicit
Private m_lngItemIndex As Long
Private m_lngItemNum As Long

Private m_strItemName(0 To 11) As String
Private m_strItemInfo(0 To 11) As String

Event ItemClick(Index As Integer, strItem As String, strInfo As String)
Event ItemMove(Index As Integer, strItem As String, strInfo As String)

'*************************************************************************
'**函 数 名:lblSelect_Click
'**输    入:Index(Integer) -
'**输    出:无
'**功能描述:
'**全局变量:
'**调用模块:
'**作    者:叶帆
'**日    期:2005-11-09 17:31:57
'**修 改 人:
'**日    期:
'**版    本:V1.0.0
'*************************************************************************
Private Sub lblSelect_Click(Index As Integer)
    imgSelect.Top = lblSelect(Index).Top - 2
    m_lngItemIndex = Index
    lblInfo.Caption = m_strItemInfo(Index)
    
    RaiseEvent ItemClick(Index, m_strItemName(Index), m_strItemInfo(Index))
End Sub

'*************************************************************************
'**函 数 名:lblSelect_MouseMove
'**输    入:Index(Integer)  -
'**        :Button(Integer) -
'**        :Shift(Integer)  -
'**        :X(Single)       -
'**        :Y(Single)       -
'**输    出:无
'**功能描述:
'**全局变量:
'**调用模块:
'**作    者:叶帆
'**日    期:2005-11-09 16:29:10
'**修 改 人:
'**日    期:
'**版    本:V1.0.0
'*************************************************************************
Private Sub lblSelect_MouseMove(Index As Integer, Button As Integer, Shift As Integer, X As Single, Y As Single)
   shpMenu.Top = lblSelect(Index).Top - 6
   
   If m_lngItemIndex = Index Then
      imgSelect.Picture = imgFlag(1).Picture
   Else
      imgSelect.Picture = imgFlag(0).Picture
   End If
   
   RaiseEvent ItemMove(Index, m_strItemName(Index), m_strItemInfo(Index))
   
End Sub

'*************************************************************************
'**函 数 名:UserControl_Initialize
'**输    入:无
'**输    出:无
'**功能描述:
'**全局变量:
'**调用模块:
'**作    者:叶帆
'**日    期:2005-11-09 15:59:29
'**修 改 人:
'**日    期:
'**版    本:V1.0.0
'*************************************************************************
Private Sub UserControl_Initialize()
    SetItem "基本配置|系统配置|关于", "叶帆软件系列 - 基本配置|叶帆软件系列 - 系统配置|叶帆软件系列 - 关于"
End Sub

'*************************************************************************
'**函 数 名:UserControl_Resize
'**输    入:无
'**输    出:无
'**功能描述:
'**全局变量:
'**调用模块:
'**作    者:叶帆
'**日    期:2005-11-09 16:21:43
'**修 改 人:
'**日    期:
'**版    本:V1.0.0
'*************************************************************************
Private Sub UserControl_Resize()
   UserControl.Width = 8610
   UserControl.Height = 5390
End Sub


'*************************************************************************
'**函 数 名:SetItem
'**输    入:strItem(String) - 用|分割的字符串  选项
'**        :strInfo(String) - 用|分割的字符串  选项信息
'**输    出:无
'**功能描述:设置选项
'**全局变量:
'**调用模块:
'**作    者:叶帆
'**日    期:2005-11-09 22:02:31
'**修 改 人:
'**日    期:
'**版    本:V1.0.0
'*************************************************************************
Public Sub SetItem(strItem As String, strInfo As String)
    Dim i As Long
    Dim strData() As String
    Dim strDatas() As String

    If Len(strItem) = 0 Or Len(strInfo) = 0 Then
        Exit Sub
    End If

    strData = Split(strItem, "|")
    strDatas = Split(strInfo, "|")

    m_lngItemNum = UBound(strData) + 1

    If m_lngItemNum > 12 Then
        m_lngItemNum = 12
    End If

    For i = 0 To m_lngItemNum - 1
        m_strItemName(i) = strData(i)

        If i <= UBound(strDatas) Then
            m_strItemInfo(i) = strDatas(i)
        Else
            m_strItemInfo(i) = strData(i)
        End If
    Next

    For i = 1 To lblSelect.Count - 1
        Unload lblSelect(i)
        Unload linBar(i)
    Next

    lblSelect(0).Caption = m_strItemName(0)
    For i = 1 To m_lngItemNum - 1
        Load lblSelect(i)
        lblSelect(i).Visible = True
        lblSelect(i).Top = lblSelect(0).Top + 25 * i
        lblSelect(i).Caption = m_strItemName(i)
        lblSelect(i).ZOrder 0

        Load linBar(i)
        linBar(i).Visible = True
        linBar(i).Y1 = linBar(0).Y1 + 25 * i
        linBar(i).Y2 = linBar(i).Y1
    Next

    shpBar1.ZOrder 1

    '----------------------
    m_lngItemIndex = 0
    imgSelect.Top = lblSelect(m_lngItemIndex).Top - 2
    lblInfo.Caption = m_strItemInfo(m_lngItemIndex)

End Sub

⌨️ 快捷键说明

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