- ©«¤l
- 4901
- ¥DÃD
- 44
- ºëµØ
- 24
- ¿n¤À
- 4916
- ÂI¦W
- 276
- §@·~¨t²Î
- Windows 7
- ³nÅ骩¥»
- Office 20xx
- ¾\ŪÅv
- 150
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥x¥_
- µù¥U®É¶¡
- 2010-4-30
- ³Ì«áµn¿ý
- 2024-12-22
|
¦^´_ 22# PD961A
¬JµM¤£·Q¦h¤@Äæ¿é¤J¤½¦¡,¦Ó±Ä¥ÎVBA,¤S©ÈÃC¦â¤Ó¶Ã,¤Snª¾¹Dþ´X®æ«½Æ,¨º´N¥Îµù¸Ñª«¥óÀx¦s¦p¦ó?- Private Sub Worksheet_Change(ByVal Target As Range)
- Dim Rng As Range, A As Range, d As Object
- Set d = CreateObject("Scripting.Dictionary")
- If Target.Column <> 7 Then Exit Sub
- For Each A In Range("G13:G65536").SpecialCells(xlCellTypeConstants)
- If Application.CountIf(Columns("G"), A) > 1 Then
- If IsEmpty(d(A.Value)) Then
- Set d(A.Value) = A
- Else
- Set d(A.Value) = Union(d(A.Value), A)
- End If
- End If
- Next
- For Each A In Range("G:G").SpecialCells(xlCellTypeConstants)
- If Not IsEmpty(d(A.Value)) Then
- For Each Rng In d(A.Value)
- If Rng.Comment Is Nothing Then
- Rng.AddComment.Text Text:=d(A.Value).Address(0, 0)
- Else
- Rng.Comment.Text Text:=d(A.Value).Address(0, 0)
- End If
- Next
- End If
- Next
- End Sub
½Æ»s¥N½X |
|