- ©«¤l
- 17
- ¥DÃD
- 4
- ºëµØ
- 0
- ¿n¤À
- 58
- ÂI¦W
- 2
- §@·~¨t²Î
- Win 7
- ³nÅ骩¥»
- Office 2010
- ¾\ŪÅv
- 20
- µù¥U®É¶¡
- 2015-3-15
- ³Ì«áµn¿ý
- 2024-4-19
|
[¤À¨É] ¦brange¤¤´M§ä¦Û¤w·QnªºÈ¡A¨Ã¥B©³®æÅܦâ
µ¹¦U¦ì§@¤À¨É¤F¡A¤p§Ì¤]¬O±q½×¾Â¤W§ä¸ê®Æ¦Û¤w½sĶªº¡C
Sub Find()
Dim FindString As Integer
Dim FirstAddress As String
FindString = InputBox("½Ð¿é¤J¼ÆÈ")
Dim oRng As Range
Set oRng = Range("E1:I3000").Find(what:=FindString, LookIn:=xlValues, lookat:=xlWhole, searchorder:=xlRows, matchbyte:=True)
If Not oRng Is Nothing Then
FirstAddress = oRng.Address
Do
Debug.Print oRng.Row, oRng.Address, oRng.Value
Set oRng = Range("E1:I3000").FindNext(oRng)
oRng.Interior.ColorIndex = 4
oRng.Offset(0, 7).Interior.ColorIndex = 4
Loop While Not oRng Is Nothing And oRng.Address <> FirstAddress
End If
End Sub |
|