begin.frm
来自「Custom Visual Basic Packager and Install」· FRM 代码 · 共 272 行
FRM
272 行
VERSION 5.00
Begin VB.Form frmBegin
BorderStyle = 3 'Fixed Dialog
Caption = "The Software Installation Wizard"
ClientHeight = 6195
ClientLeft = 1740
ClientTop = 1410
ClientWidth = 7545
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Icon = "begin.frx":0000
LinkMode = 1 'Source
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 6195
ScaleWidth = 7545
Begin VB.Frame Frame1
Height = 1215
Left = -120
TabIndex = 8
Top = 5040
Width = 7815
Begin VB.CommandButton cmdExit
Cancel = -1 'True
Caption = "Exit Setup"
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 420
Left = 5520
MaskColor = &H00000000&
TabIndex = 9
Top = 480
Width = 1725
End
End
Begin VB.CommandButton cmdInstall
Default = -1 'True
Height = 1080
Left = 330
MaskColor = &H0000FF00&
Picture = "begin.frx":0442
Style = 1 'Graphical
TabIndex = 0
Top = 1710
UseMaskColor = -1 'True
Width = 6930
End
Begin VB.Frame fraDir
Caption = "Directory"
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 1485
Left = 135
TabIndex = 4
Top = 3210
Width = 7296
Begin VB.CommandButton cmdChDir
Caption = "&Change Directory"
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 390
Left = 120
MaskColor = &H00000000&
TabIndex = 1
Top = 840
Width = 6855
End
Begin VB.Label lblDestDir
Caption = "C:\Program Files\"
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 240
Left = 135
TabIndex = 5
Top = 300
Width = 6960
End
End
Begin VB.PictureBox Picture1
Appearance = 0 'Flat
BackColor = &H80000005&
ForeColor = &H80000008&
Height = 975
Left = 0
Picture = "begin.frx":0C44
ScaleHeight = 945
ScaleWidth = 8145
TabIndex = 6
Top = 0
Width = 8175
Begin VB.Label lblapp
AutoSize = -1 'True
BackStyle = 0 'Transparent
BeginProperty Font
Name = "Times New Roman"
Size = 15.75
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00C00000&
Height = 360
Left = 960
TabIndex = 7
Top = 240
Width = 75
End
End
Begin VB.Line linTopOfExitButtonIfNoDestDir
Visible = 0 'False
X1 = 2670
X2 = 4725
Y1 = 3480
Y2 = 3480
End
Begin VB.Label lblInstallMsg
AutoSize = -1 'True
Caption = "Click this button to install the software to your computer."
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 195
Left = 600
TabIndex = 3
Top = 3000
Width = 5565
WordWrap = -1 'True
End
Begin VB.Label lblBegin
AutoSize = -1 'True
Caption = "Begin the installation by clicking the button below."
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 195
Left = 285
TabIndex = 2
Top = 1335
Width = 6450
WordWrap = -1 'True
End
End
Attribute VB_Name = "frmBegin"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Option Compare Text
' Constants/Types for a simulated "picture button"
Const x3DLineWidth = 1 '"Width" of highlight/shadow "lines"
Const y3DLineWidth = x3DLineWidth
Const pbXDeltaMouseDown = x3DLineWidth
Const pbYDeltaMouseDown = y3DLineWidth
Private fMouseDown As Boolean
Private Sub cmdChDir_Click()
ShowPathDialog gstrDIR_DEST
If gfRetVal = gintRET_CONT Then
lblDestDir.Caption = gstrDestDir
cmdInstall.SetFocus
End If
End Sub
Private Sub cmdExit_Click()
ExitSetup Me, gintRET_EXIT
End Sub
Private Sub cmdInstall_Click()
If IsValidDestDir(gstrDestDir) = True Then
Unload Me
DoEvents
End If
End Sub
Private Sub Form_Load()
SetFormFont Me
lblapp.Caption = gstrAppName + " Installation wizard"
fraDir.Caption = ResolveResString(resFRMDIRECTORY)
cmdChDir.Caption = ResolveResString(resBTNCHGDIR)
cmdExit.Caption = ResolveResString(resBTNEXIT)
lblBegin.Caption = ResolveResString(resLBLBEGIN)
cmdInstall.ToolTipText = ResolveResString(resBTNTOOLTIPBEGIN)
Caption = gstrTitle
lblInstallMsg.Caption = ResolveResString(IIf(gfForceUseDefDest, resSPECNODEST, resSPECDEST), "|1", gstrAppName)
lblDestDir.Caption = gstrDestDir
If gfForceUseDefDest Then
'We are forced to use the default destination directory, so the user
' will not be able to change it.
fraDir.Visible = False
'Close in the blank space on the form by moving the Exit button to where this frame
'currently is, and adjusting the size of the form respectively
Dim yAdjust As Integer
yAdjust = cmdExit.Top - linTopOfExitButtonIfNoDestDir.Y1
cmdExit.Top = cmdExit.Top - yAdjust
Height = Height - yAdjust
EtchedLine Me, fraDir.Left, cmdExit.Top - cmdExit.Height \ 2, fraDir.Width
Else
EtchedLine Me, fraDir.Left, cmdExit.Top - cmdExit.Height \ 2, fraDir.Width
End If
CenterForm Me
End Sub
Private Sub Form_QueryUnload(Cancel As Integer, UnloadMode As Integer)
If UnloadMode <> 1 Then
ExitSetup Me, gintRET_EXIT
Cancel = 1
End If
End Sub
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?