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

ÁôÂÃ

ÁôÂÃ

¦U¦ì«e½ú§A­Ì¦n!
¡@¡@      «e½ú!°ÝÃD¦pªþÀÉ®×»¡©ú¡@
           Leov9¬OÁôÂÃ
           Leov10¬O®t²§ÁÙ­ì
          ½Ðª¾¹Dªº«e½ú,¤£§[½ç±ÐÁÂÁ¦A¤T!!

Leov9.rar (29.88 KB)

Leov10.rar (23.88 KB)

¥»©«³Ì«á¥Ñ victorl ©ó 2010-6-17 00:39 ½s¿è

For Leov9
§â©Ò¦³½d³ò¥ýÁôÂæA±N¿ï¨ú±ý§e²{ªº½d³òÅã¥Ü¡AÀ³¸Ó´NOK¤F§a
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
    If Target.Column = 3 Then
        Rows("13:72").Hidden = True   
        Rows(Target.Row - 1 & ":" & Target.Row + 10).EntireRow.Hidden = False
    End If
    Range("B1").Select
End Sub

For Leov10
§âTarget.Row·í¤Þ¼Æ©I¥sµ{§Ç(Ex. Call ½T©w®t²§ÁÙ­ì(Target.Row))
¤U¤èÂŦⳡ¤À¬°­ìµ{¦¡½X¦³­×§ï³¡¤À.
Sub ½T©w®t²§ÁÙ­ì(tRow As Integer)
          ...
    ElseIf [A1] = "³¡¥÷" Then Call ®t²§³¡¥÷ÁÙ­ì(tRow)
          ...
Sub ®t²§³¡¥÷ÁÙ­ì(tRow As Integer)
    Range(Cells(tRow - 1, 3), Cells(tRow + 10, 256)).Copy Sheet11.[C65536].End(xlUp).Offset(0, 0)
    Sheet11.Select
End Sub

TOP

¥»©«³Ì«á¥Ñ GBKEE ©ó 2010-6-17 08:04 ½s¿è

¦^´_ 1# myleoyes
  1. Private Sub Worksheet_SelectionChange(ByVal Target As Range)
  2.      Select Case Target(1).Address(0, 0)
  3.         Case "A1"
  4.             Äæ
  5.         Case "B1"
  6.             ¦C
  7.     End Select
  8.     If Not Intersect(Target(1), Range("C13:C" & Rows.Count)) Is Nothing Then
  9. 'Love10 ¦P²z
  10.     If Target(1).Column = 3 And Target(1) <> "" Then ÁôÂÃ
  11.     End If
  12. End Sub

  13. ''''''''''''''''''''''''''''''''''''''''''''''''''''
  14. Sub ÁôÂÃ()
  15.     Dim R
  16.     R = (ActiveCell.Row Mod 12)
  17.     If R = 0 Then
  18.         R = ActiveCell.Row - 11 & ":" & ActiveCell.Row
  19.     Else
  20.         R = ActiveCell.Row - R + 1 & ":" & ActiveCell.Row + (12 - R)
  21.     End If
  22.     Rows("13:" & Rows.Count).EntireRow.Hidden = True
  23.     Rows(R).EntireRow.Hidden = False
  24. End Sub
  25. ''''''''''''''''''''''''''''''''''''''''''''''''''''
  26. Sub ®t²§³¡¥÷ÁÙ­ì()
  27.     Dim R
  28.     R = (ActiveCell.Row Mod 12)
  29.     If R = 0 Then
  30.         R = "C" & ActiveCell.Row - 11 & ":IV" & ActiveCell.Row
  31.     Else
  32.         R = "C" & ActiveCell.Row - R + 1 & ":IV" & ActiveCell.Row + (12 - R)
  33.     End If
  34.     Range(R).Copy Sheet11.[C65536].End(xlUp).Offset(0, 0)
  35.     Sheet11.Select
  36. End Sub
½Æ»s¥N½X

TOP

¦^´_ 3# GBKEE
victorl «e½ú§A¦n!
       «e½úÁÂÁÂ!!
       For Leov9³o¼ËÁôÂìO¹ïªº
       ¦ý¬O¥u­n¸I¨ì¨ä¥LÀx¦s®æ
       ´N·|°õ¦æÁôÂÃ,·|®{¼W§xÂZ
       ¦Ü©óFor Leov10³o¬qµ{¦¡
       §âTarget.Row·í¤Þ¼Æ©I¥sµ{§Ç(Ex. Call ½T©w®t²§ÁÙ­ì(Target.Row))
       ¤p§ÌµLªk²z¸Ñ©|½Ð«e³Æ«ü¾ÉÁÂÁ¦A¤T!

GBKEE«e½ú§A¦n!
¡@¡@¡@¡@ ¨}®v!°ÝÃD1,2¦pªþÀÉ»¡©ú
               ¤S¦A³Â·Ð§AÅo!ÁÂÁ¦A¤T!!

Leov9-1.rar (40.09 KB)

Leov10-1.rar (24.17 KB)

TOP

¦^´_ 4# myleoyes
  1. Sub ÁôÂÃ()
  2.     Dim R
  3.     R = (ActiveCell.Row Mod 12)
  4.     If R = 2 Then
  5.          R = ActiveCell.Row - R + 1 & ":" & ActiveCell.Row + (12 - R)
  6.         Rows("13:" & Rows.Count).EntireRow.Hidden = True
  7.         Rows(R).EntireRow.Hidden = False
  8.     End If
  9. End Sub
½Æ»s¥N½X
  1. Sub ®t²§³¡¥÷ÁÙ­ì()
  2.     Dim R, Rng As Range
  3.     R = (ActiveCell.Row Mod 12)
  4.     If R = 0 Then
  5.         R = "C" & ActiveCell.Row - 11 & ":IV" & ActiveCell.Row
  6.     Else
  7.         R = "C" & ActiveCell.Row - R + 1 & ":IV" & ActiveCell.Row + (12 - R)
  8.     End If
  9.     Set Rng = Sheet11.[C65536].End(xlUp).Offset(1)
  10.     If Sheet11.[C65536].End(xlUp).Row = 1 Then Set Rng = Sheet11.[C65536].End(xlUp)
  11.     Range(R).Copy Rng
  12.     Sheet11.Select
  13. End Sub
½Æ»s¥N½X

TOP

·PÁÂGBKEEª©¤j¡A¤p§Ì¨ü±Ð¤F¡F³ºµM©¿²¤±¼¤F Target=ActiveCell¡C

TOP

¦^´_ 6# victorl
   Target.Cells(1) = ActiveCell
   Target = Selection

TOP

¦^´_ 7# GBKEE
GBKEE«e½ú§A¦n!
¡@¡@¡@¡@ ¨}®v!ºÃ´b³o©«©ú©ú·í¤Ñ´N¦^ÂÐ!
             ¬°¦ó?¤S¤£¨£¤å³¹??³o¼Ë¤]¦n
                ¥t¤@°ÝÃD¬Q¤é¸Ñ¤@¾ã¤ÑµLªk§Ë¦¨
                ªþÀɽЦAÀ°¦£ÁÂÁ¦A¤T!!

Leov9-2.rar (92.87 KB)

TOP

¦^´_ 8# myleoyes
  1. Sub ¦h­«¿ï¨ú()
  2.     Dim R, A As Range
  3.     Rows("3:" & Rows.Count).EntireRow.Hidden = True
  4.     'ÁôÂ꺽d³ò¤º¦p¦³¥ô¦óªºª«¥ó«h -> .Hidden = True ·|²£¥Í¿ù»~
  5.    'Sheets("®t²§³Æ¥÷")²Ä2¦Cªº¦C°ª ½Ð½Õ°ª¤@¨Ç ©Î [¨ú®ø] «ö¶s ¤W²¾ OR ÁY¤p
  6.    '§_«h °õ¦æ¤W­±µ{¦¡½X·|²£¥Í¿ù»~
  7.     For Each A In Selection.Areas  '¿ï¨úC16+C40+...ªº½d³ò
  8.         If A.Row <= 14 Then
  9.             R = 3 & ":" & 14
  10.         Else
  11.             R = Int((A.Row - 3) / 12)
  12.             R = 3 + (12 * R) & ":" & 3 + (12 * (R + 1)) - 1
  13.         End If
  14.         Rows(R).EntireRow.Hidden = False
  15.     Next
  16. End Sub
½Æ»s¥N½X

TOP

¦^´_ 9# GBKEE
GBKEE«e½ú§A¦n!
¡@¡@¡@¡@ ¨}®v!¨¯­WÅo!!ÁÂÁ¦A¤T!!

TOP

        ÀR«ä¦Û¦b : ·R¤£¬O­n¨D¹ï¤è¡A¦Ó¬O­n¥Ñ¦Û¨­ªº¥I¥X¡C
ªð¦^¦Cªí ¤W¤@¥DÃD