📄 frmorder.frm
字号:
VERSION 5.00
Begin VB.Form frmOrder
Caption = "Form1"
ClientHeight = 5550
ClientLeft = 60
ClientTop = 345
ClientWidth = 8820
LinkTopic = "Form1"
ScaleHeight = 5550
ScaleWidth = 8820
StartUpPosition = 3 '窗口缺省
Begin VB.CommandButton cmdExit
Caption = "Exit"
Height = 615
Left = 6480
TabIndex = 20
Top = 4680
Width = 1935
End
Begin VB.CommandButton cmdClear
Caption = "Clear Screen"
Height = 615
Left = 4320
TabIndex = 19
Top = 4680
Width = 1935
End
Begin VB.CommandButton cmdPrint
Caption = "Print Order"
Height = 615
Left = 2160
TabIndex = 18
Top = 4680
Width = 1935
End
Begin VB.CommandButton cmdCalc
Caption = "Calculate Order"
Height = 615
Left = 240
TabIndex = 17
Top = 4680
Width = 1695
End
Begin VB.TextBox txtName
Height = 375
Left = 960
TabIndex = 0
Top = 720
Width = 2775
End
Begin VB.TextBox txtAddress
Height = 375
Left = 960
TabIndex = 2
Top = 1320
Width = 2775
End
Begin VB.TextBox txtCity
Height = 375
Left = 960
TabIndex = 4
Top = 1920
Width = 2775
End
Begin VB.TextBox txtState
Height = 375
Left = 960
TabIndex = 6
Text = "IL"
Top = 2520
Width = 975
End
Begin VB.TextBox txtZip
Height = 375
Left = 2640
TabIndex = 8
Top = 2520
Width = 1095
End
Begin VB.TextBox txtPrice
Height = 375
Left = 6120
TabIndex = 14
Top = 720
Width = 1215
End
Begin VB.TextBox txtRate
Height = 375
Left = 6120
TabIndex = 16
Top = 1320
Width = 1215
End
Begin VB.TextBox txtBlue
Height = 375
Left = 2640
TabIndex = 10
Top = 3120
Width = 1095
End
Begin VB.TextBox txtYellow
Height = 375
Left = 2640
TabIndex = 12
Top = 3720
Width = 1095
End
Begin VB.Label lblTprice
Height = 420
Left = 6120
TabIndex = 26
Top = 2520
Width = 1290
End
Begin VB.Label lblTboards
Height = 375
Left = 6120
TabIndex = 25
Top = 1920
Width = 1215
End
Begin VB.Label lblBiaoti
AutoSize = -1 'True
Caption = "Skate-Away Sales Oredr Form"
BeginProperty Font
Name = "宋体"
Size = 12
Charset = 134
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 240
Left = 2520
TabIndex = 24
Top = 360
Width = 3240
End
Begin VB.Label lblName
AutoSize = -1 'True
Caption = "Name:"
Height = 180
Left = 120
TabIndex = 23
Top = 840
Width = 450
End
Begin VB.Label lblAddress
AutoSize = -1 'True
Caption = "Address:"
Height = 180
Left = 120
TabIndex = 22
Top = 1440
Width = 720
End
Begin VB.Label lblCity
AutoSize = -1 'True
Caption = "City:"
Height = 180
Left = 120
TabIndex = 21
Top = 2040
Width = 450
End
Begin VB.Label lblState
AutoSize = -1 'True
Caption = "State:"
Height = 180
Left = 120
TabIndex = 15
Top = 2640
Width = 540
End
Begin VB.Label lblZip
AutoSize = -1 'True
Caption = "Zip:"
Height = 180
Left = 2160
TabIndex = 13
Top = 2640
Width = 360
End
Begin VB.Label lblPrice
AutoSize = -1 'True
Caption = "Skateboard price:"
Height = 180
Left = 4440
TabIndex = 11
Top = 840
Width = 1530
End
Begin VB.Label lblRate
AutoSize = -1 'True
Caption = "Sales tax rate:"
Height = 180
Left = 4440
TabIndex = 9
Top = 1440
Width = 1350
End
Begin VB.Label lblTotalS
AutoSize = -1 'True
Caption = "Total skateboards:"
Height = 180
Left = 4440
TabIndex = 7
Top = 2040
Width = 1620
End
Begin VB.Label lblTotalP
AutoSize = -1 'True
Caption = "Total price:"
Height = 180
Left = 4440
TabIndex = 5
Top = 2640
Width = 1080
End
Begin VB.Label lblBlue
AutoSize = -1 'True
Caption = "Blue skateboards ordered:"
Height = 180
Left = 120
TabIndex = 3
Top = 3240
Width = 2250
End
Begin VB.Label lblYellow
AutoSize = -1 'True
Caption = "Yellow skateboards ordered:"
Height = 180
Left = 120
TabIndex = 1
Top = 3840
Width = 2430
End
End
Attribute VB_Name = "frmOrder"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Label5_Click()
End Sub
Private Sub cmdCalc_Click()
lblTboards.Caption = Val(txtBlue.Text) + Val(txtYellow.Text)
lblTprice.Caption = Val(lblTboards.Caption) * Val(txtPrice.Text) * (1 + Val(txtRate.Text))
lblTprice.Caption = Format(lblTprice.Caption, "currency")
cmdPrint.SetFocus
End Sub
Private Sub cmdClear_Click()
txtName.Text = ""
txtAddress.Text = ""
txtCity.Text = ""
txtState.Text = "IL"
txtZip.Text = ""
txtBlue.Text = ""
txtYellow.Text = ""
lblTboards.Caption = ""
lblTprice.Caption = ""
txtName.SetFocus
End Sub
Private Sub cmdExit_Click()
Unload Me
End Sub
Private Sub cmdPrint_Click()
cmdCalc.Visible = False
cmdPrint.Visible = False
cmdClear.Visible = False
cmdExit.Visible = False
PrintForm
cmdCalc.Visible = True
cmdPrint.Visible = True
cmdClear.Visible = True
cmdExit.Visible = True
cmdClear.SetFocus
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -