ªð¦^¦Cªí ¤W¤@¥DÃD µo©«

[µo°Ý] ¦p¦ó±oª¾´¡¤J½Æ»sÀx¦s®æªº¦æ¼Æ?

[µo°Ý] ¦p¦ó±oª¾´¡¤J½Æ»sÀx¦s®æªº¦æ¼Æ?

Hello, ¦U¦ì¤j¤j

       °²³]¨Ï¥ÎªÌ¦bSheetB½Æ»s¤F¤@¨Ç¦æ¼Æ(EX:2~6Rows),
       ¨Ã¦bSheetAªº²Ä3¦æ°µ´¡¤J½Æ»sÀx¦s®æªº°Ê§@.
       ½Ð°Ý, ¨t²Î­n¦p¦ó°»´ú¨Ï¥ÎªÌ´¡¤Jªº¦æ¼Æ¬O¦h¤Ö?
  
       Rows«ü¥OµLªk°»´ú¥X¨Ó.

      Private Sub Worksheet_Change(ByVal Target As Range)

                   MsgBox Target.Rows

      End Sub

Thanks ~
·s¤â¤W¸ô¡A½Ð¦h¥]²[¡C

Target.Rows.count
{...} ªí¥Ü»Ý­n¥Î CTRL+SHIFT+ENTER ¤TÁä¿é¤J¤½¦¡

TOP

Hello, ML089¤j

    ¤F¸Ñ! ÁÂÁ±zªº¦^ÂÐ.
·s¤â¤W¸ô¡A½Ð¦h¥]²[¡C

TOP

¦^´_ 2# ML089


    Hello, ML089¤j

¤µ¤éµo²{´¡¤J»P§R°£ªºRows.count³£¬O5, ¨t²Î­n¦p¦ó¤À¿ëUser¬O¦b°µ´¡¤J, ÁÙ¬O§R°£ªº°Ê§@©O?
Thanks ~
·s¤â¤W¸ô¡A½Ð¦h¥]²[¡C

TOP

¦^´_ 4# ¼B¤j­G

¤£ª¾¹DVBA¸Ì¦³µL¦¹¥\¯à¨ç¼Æ

¦Û¦æ©ó¤u§@ªí¸Ì©w¸q¡A¥i¯à¤£¬O«Ü§¹µ½¡A¥ý±N´N¥Î¬Ý¬Ý
Public rTmp As Range, sTmpAdr As String

Private Sub Worksheet_Change(ByVal Target As Range)
    Debug.Print Target.Address, "Worksheet_Change"
   
    '§R°£®É rTmp ª«¥ó·|¤£¨£³y¦¨¿ù»~
    On Error Resume Next
    rTmpAdr = "µL": rTmpAdr = rTmp.Address
    On Error GoTo 0
   
    Debug.Print rTmpAdr, "rTmpAdr"
    Debug.Print sTmpAdr, "sTmpAdr"
   
    If rTmpAdr = "µL" Then
        Debug.Print "§R°£ " & sTmpAdr
    ElseIf rTmpAdr <> sTmpAdr Then
        Debug.Print "´¡¤J " & sTmpAdr
    ElseIf rTmpAdr = sTmpAdr Then
        Debug.Print "­×§ï " & sTmpAdr
    Else
        Debug.Print "¨ä¥L " & sTmpAdr
    End If
End Sub

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
    Debug.Print Target.Address, "Worksheet_SelectionChange"
    Set rTmp = Target: sTmpAdr = rTmp.Address
End Sub
{...} ªí¥Ü»Ý­n¥Î CTRL+SHIFT+ENTER ¤TÁä¿é¤J¤½¦¡

TOP

¦^´_ 5# ML089
Hello, ¤j¤j

            ÁÂÁ±zªº¦^ÂÐ, §Ú¦A¬ã¨s¤@¤U±zªºµ{¦¡.
·s¤â¤W¸ô¡A½Ð¦h¥]²[¡C

TOP

        ÀR«ä¦Û¦b : ¥¬¬I¦p¼½ºØ¡A¥HÅw³ß¤ß´þ¼íºØ¤l¡A¤~·|µoªÞ¡C
ªð¦^¦Cªí ¤W¤@¥DÃD