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

📄 frmatalhos.frm

📁 A good aplication to see some components like better button and vertical menu. Works with GP3 to con
💻 FRM
字号:
VERSION 5.00
Object = "{3EF16C9D-EC6F-11D2-B926-00AA00597EDB}#2.2#0"; "VARBETTERBUTTON.OCX"
Object = "{F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0"; "COMDLG32.OCX"
Begin VB.Form frmAtalhos 
   BackColor       =   &H00FFFFFF&
   BorderStyle     =   3  'Fixed Dialog
   Caption         =   "Configura玢o de Atalho"
   ClientHeight    =   3195
   ClientLeft      =   45
   ClientTop       =   330
   ClientWidth     =   4695
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MDIChild        =   -1  'True
   MinButton       =   0   'False
   Moveable        =   0   'False
   ScaleHeight     =   3195
   ScaleWidth      =   4695
   ShowInTaskbar   =   0   'False
   Begin VB.CommandButton cmdSelecionar 
      BackColor       =   &H00FFFFFF&
      Caption         =   "..."
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   8.25
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   4140
      MaskColor       =   &H00FFFFFF&
      TabIndex        =   2
      ToolTipText     =   "Clique aqui para selecionar o programa"
      Top             =   360
      Width           =   375
   End
   Begin VB.TextBox txtNomeAtalho 
      Height          =   375
      Left            =   180
      MaxLength       =   20
      TabIndex        =   1
      Top             =   1200
      Width           =   3855
   End
   Begin VB.CommandButton cmdSelecionarIcone 
      BackColor       =   &H00FFFFFF&
      Caption         =   "..."
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   8.25
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   375
      Left            =   4140
      MaskColor       =   &H00FFFFFF&
      TabIndex        =   0
      ToolTipText     =   "Clique aqui para selecionar o 韈one"
      Top             =   2040
      Width           =   375
   End
   Begin MSComDlg.CommonDialog cd2 
      Left            =   4020
      Top             =   1560
      _ExtentX        =   847
      _ExtentY        =   847
      _Version        =   393216
      Filter          =   "Figuras|*.ico;*.jpg;*.bmp;*.gif|Programas|*.exe"
   End
   Begin MSComDlg.CommonDialog cd1 
      Left            =   4020
      Top             =   720
      _ExtentX        =   847
      _ExtentY        =   847
      _Version        =   393216
      DefaultExt      =   "*.exe"
      DialogTitle     =   "Selecione o programa"
      Filter          =   "*.exe|*.exe"
   End
   Begin varBetterButton.BetterButton cmdOk 
      Height          =   435
      Left            =   2880
      TabIndex        =   3
      ToolTipText     =   "Confirma configura珲es"
      Top             =   2520
      Width           =   1635
      _ExtentX        =   2884
      _ExtentY        =   767
      Caption         =   "&Ok"
      BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
         Name            =   "MS Sans Serif"
         Size            =   8.25
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      BackColor       =   16777215
      ForeColor       =   8388608
      HighlightColor  =   16777215
      ShadowColor     =   11184810
      BorderColor     =   0
      DisabledColor   =   11184810
      PictureOver     =   "frmAtalhos.frx":0000
      ShowFocus       =   0   'False
      ShowDefault     =   0   'False
      Style           =   1
      MousePointer    =   0
   End
   Begin varBetterButton.BetterButton cmdCancelar 
      Height          =   435
      Left            =   1140
      TabIndex        =   4
      ToolTipText     =   "Ignora altera珲es na configura玢o"
      Top             =   2520
      Width           =   1635
      _ExtentX        =   2884
      _ExtentY        =   767
      Caption         =   "&Cancelar"
      BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
         Name            =   "MS Sans Serif"
         Size            =   8.25
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      BackColor       =   16777215
      ForeColor       =   8388608
      HighlightColor  =   16777215
      ShadowColor     =   11184810
      BorderColor     =   0
      DisabledColor   =   11184810
      PictureOver     =   "frmAtalhos.frx":039A
      ShowFocus       =   0   'False
      ShowDefault     =   0   'False
      Style           =   1
      MousePointer    =   0
   End
   Begin VB.Label Label1 
      AutoSize        =   -1  'True
      BackStyle       =   0  'Transparent
      Caption         =   "Programa"
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   8.25
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H0000FFFF&
      Height          =   195
      Left            =   180
      TabIndex        =   9
      Top             =   120
      Width           =   810
   End
   Begin VB.Label lblPrograma 
      BackColor       =   &H00FFFFFF&
      BorderStyle     =   1  'Fixed Single
      Height          =   375
      Left            =   180
      TabIndex        =   8
      Top             =   360
      Width           =   3855
   End
   Begin VB.Label Label2 
      AutoSize        =   -1  'True
      BackStyle       =   0  'Transparent
      Caption         =   "Nome do Atalho"
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   8.25
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H0000FFFF&
      Height          =   195
      Left            =   180
      TabIndex        =   7
      Top             =   900
      Width           =   1365
   End
   Begin VB.Label Label3 
      AutoSize        =   -1  'True
      BackStyle       =   0  'Transparent
      Caption         =   "蚦one"
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   8.25
         Charset         =   0
         Weight          =   700
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H0000FFFF&
      Height          =   195
      Left            =   180
      TabIndex        =   6
      Top             =   1800
      Width           =   495
   End
   Begin VB.Label lblIcone 
      BackColor       =   &H00FFFFFF&
      BorderStyle     =   1  'Fixed Single
      Height          =   375
      Left            =   180
      TabIndex        =   5
      Top             =   2040
      Width           =   3855
   End
   Begin VB.Image imgIcone 
      Height          =   495
      Left            =   180
      Stretch         =   -1  'True
      Top             =   2460
      Width           =   495
   End
End
Attribute VB_Name = "frmAtalhos"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False



Private Sub cmdCancelar_MouseDown(Button As Integer, Shift As Integer, x As Single, y As Single)

    Unload Me

End Sub

Private Sub cmdOk_MouseDown(Button As Integer, Shift As Integer, x As Single, y As Single)

    Me.MousePointer = 11
    MDIGP3.vtmMenu.MenuItemCaption = txtNomeAtalho.Text
    'MDIGP3.vtmMenu.MenuItemIcon = LoadPicture(lblIcone.Caption)
    Set rsAuxiliar = DBGP3.OpenRecordset("Atalhos")
    rsAuxiliar.Index = "PrimaryKey"
    rsAuxiliar.Seek "=", Mid(frmAtalhos.Caption, Len(frmAtalhos.Caption) - 1, 1)
    If rsAuxiliar.NoMatch Then
        rsAuxiliar.AddNew
        rsAuxiliar("Codigo") = Mid(frmAtalhos.Caption, Len(frmAtalhos.Caption) - 1, 1)
    Else
        rsAuxiliar.Edit
    End If
    rsAuxiliar("Programa") = lblPrograma.Caption
    rsAuxiliar("NomeAtalho") = txtNomeAtalho.Text
    rsAuxiliar("Icone") = lblIcone.Caption
    rsAuxiliar.Update
    rsAuxiliar.Close
    Me.MousePointer = 0
    Unload Me

End Sub

Private Sub cmdSelecionar_Click()
On Error GoTo TrataErro

    cd1.Action = 1
    lblPrograma.Caption = cd1.FileName
    lblIcone.Caption = cd1.FileName
    Exit Sub

TrataErro:
    MsgBox Error & Err
    
End Sub



Private Sub cmdSelecionarIcone_Click()
On Error GoTo TrataErro

    cd2.Action = 1
    lblIcone.Caption = cd2.FileName
    Exit Sub

TrataErro:
    

End Sub


Private Sub Form_Load()

    Me.Left = 10
    Me.Top = 10
    FadeForm Me, False, False, True

End Sub

Private Sub lblIcone_Change()

    'imgIcone.Picture = LoadPicture(lblIcone.Caption)

End Sub

⌨️ 快捷键说明

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