📄 form1.frm
字号:
VERSION 5.00
Begin VB.Form Form1
Caption = "在TextBox中设置新的系统功能菜单"
ClientHeight = 2430
ClientLeft = 2250
ClientTop = 2430
ClientWidth = 5190
LinkTopic = "Form1"
ScaleHeight = 2430
ScaleWidth = 5190
StartUpPosition = 1 '所有者中心
Begin VB.TextBox Text1
Height = 1425
Left = 120
TabIndex = 5
Text = $"Form1.frx":0000
Top = 345
Width = 2385
End
Begin VB.CommandButton Command1
Caption = "退出"
Height = 495
Left = 4035
TabIndex = 4
Top = 1845
Width = 1020
End
Begin VB.TextBox Text2
Height = 1425
Left = 2670
MultiLine = -1 'True
TabIndex = 0
Text = "Form1.frx":00F0
Top = 345
Width = 2385
End
Begin VB.Label Label1
Caption = "文本1"
Height = 255
Left = 180
TabIndex = 3
Top = 60
Width = 1545
End
Begin VB.Label Label2
Caption = "文本2"
Height = 255
Left = 2730
TabIndex = 2
Top = 60
Width = 1545
End
Begin VB.Label Label3
Caption = "在文本1按滑鼠右键弹出新的系统功能菜单;在文本2会出现默认的系统功能菜单。"
Height = 405
Left = 120
TabIndex = 1
Top = 1830
Width = 3510
WordWrap = -1 'True
End
Begin VB.Menu MYPUP
Caption = "我的菜单"
Visible = 0 'False
Begin VB.Menu password
Caption = "密码显示"
End
Begin VB.Menu NOPASSWORD
Caption = "取消密码显示"
End
Begin VB.Menu CLEAR
Caption = "清空数据"
End
End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub CLEAR_Click()
Text1.Text = ""
End Sub
Private Sub password_Click()
Text1.PasswordChar = "*"
End Sub
Private Sub NOpassword_Click()
Text1.PasswordChar = ""
End Sub
Private Sub Text1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
If Button = 2 Then
PopupMenu MYPUP
End If
End Sub
Private Sub Command1_Click()
End
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -