📄 form1.frm
字号:
VERSION 5.00
Begin VB.Form Form1
BorderStyle = 1 'Fixed Single
Caption = "表达式计算器"
ClientHeight = 3360
ClientLeft = 45
ClientTop = 330
ClientWidth = 4710
LinkTopic = "Form1"
MaxButton = 0 'False
ScaleHeight = 3360
ScaleWidth = 4710
StartUpPosition = 3 '窗口缺省
Begin VB.TextBox Res
BackColor = &H8000000F&
BeginProperty Font
Name = "宋体"
Size = 14.25
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 240
Locked = -1 'True
TabIndex = 5
Text = "2"
Top = 1080
Width = 2895
End
Begin VB.TextBox Text2
BackColor = &H8000000F&
BorderStyle = 0 'None
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 1455
Left = 240
Locked = -1 'True
MultiLine = -1 'True
TabIndex = 4
Text = "Form1.frx":0000
Top = 1800
Width = 4335
End
Begin VB.CommandButton Command1
Caption = "计算(&C)"
BeginProperty Font
Name = "宋体"
Size = 10.5
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 615
Left = 3360
TabIndex = 1
Top = 240
Width = 975
End
Begin VB.TextBox Exp
BeginProperty Font
Name = "宋体"
Size = 14.25
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 240
TabIndex = 0
Text = "1+1"
Top = 360
Width = 2895
End
Begin VB.Label Label2
Caption = "结果:"
Height = 255
Left = 240
TabIndex = 3
Top = 840
Width = 1935
End
Begin VB.Label Label1
Caption = "表达式:"
Height = 255
Left = 240
TabIndex = 2
Top = 120
Width = 1815
End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
On Error GoTo Err1:
Res.Text = Calc(Exp.Text)
Exit Sub
Err1:
MsgBox "出现错误!", vbInformation + vbOKOnly, "错误"
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -