📄 tihuan_frm.frm
字号:
VERSION 5.00
Begin VB.Form chazhao_frm
Caption = "查找"
ClientHeight = 2235
ClientLeft = 60
ClientTop = 420
ClientWidth = 4980
LinkTopic = "Form1"
ScaleHeight = 2235
ScaleWidth = 4980
StartUpPosition = 3 '窗口缺省
Begin VB.CommandButton command2
Caption = "替 换"
Height = 375
Left = 3360
TabIndex = 6
Top = 960
Width = 1335
End
Begin VB.CommandButton Command4
Caption = "取 消"
Height = 375
Left = 3360
TabIndex = 5
Top = 1560
Width = 1335
End
Begin VB.CommandButton Command1
Caption = "查找下一个"
Height = 375
Left = 3360
TabIndex = 4
Top = 360
Width = 1335
End
Begin VB.TextBox Text2
Appearance = 0 'Flat
Height = 375
Left = 1320
TabIndex = 3
Top = 1320
Width = 1815
End
Begin VB.TextBox Text1
Appearance = 0 'Flat
Height = 375
Left = 1320
TabIndex = 2
Top = 600
Width = 1815
End
Begin VB.Label Label2
Caption = "替换为:"
Height = 255
Left = 360
TabIndex = 1
Top = 1440
Width = 975
End
Begin VB.Label Label1
Caption = "查找内容:"
Height = 255
Left = 360
TabIndex = 0
Top = 720
Width = 975
End
End
Attribute VB_Name = "chazhao_frm"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim retu As Long
Private Sub Command1_Click()
If retu < Len(frmmain.Rtext.Text) Then
retu = InStr(retu, frmmain.Rtext.Text, Me.Text1.Text, vbTextCompare)
If retu > 0 Then
frmmain.Rtext.SetFocus
frmmain.Rtext.SelStart = retu - 1
frmmain.Rtext.SelLength = Len(Text1.Text)
retu = retu + 1
End If
End If
End Sub
Private Sub Command2_Click()
Dim exchange As String
exchange = Text2.Text
If retu > 0 Then
Clipboard.Clear
Clipboard.SetText frmmain.Rtext.SelText
frmmain.Rtext.SelText = exchange
End If
End Sub
Private Sub Command4_Click()
Unload Me
End Sub
Private Sub Form_Load()
retu = 1
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -