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

°ïÅ|ªÅ¶¡¤£¨¬??

°ïÅ|ªÅ¶¡¤£¨¬??

Sub RecordPrice()
Dim WR As Long
Dim I As Byte


If Range("E2") < 1 Then Exit Sub

WR = Range("A1").End(xlDown).Row + 1
If (WR = 3) Or _
   ((Second(Range("A2")) Mod 5) = 1) Then 'Á`¶q¦³²§°Ê®É¤~°O¿ý..........................³o­Ó¦a¤è¦³¼g¿ù¶Ü??ÁÙ¬O­n«ç»ò§ï¤ñ¸û¦n??
    Cells(WR, 1).Resize(, 4) = [A2:D2].Value
   End If
End Sub

°õ¦æµ{¦¡«á¬°¤°»ò·|ºÆ¨g¼g¤J¡A¥B¥X²{°ïÅ|ªÅ¶¡¤£¨¬©O??

¦^´_ 10# ­ã´£³¡ªL


    ·Ç¤j§Ú¤F¸Ñ¤F¡A·PÁ§A

TOP

Private Sub Worksheet_Calculate()
Application.EnableEvents = False
Call RecordPrice
Application.EnableEvents = True
End Sub

¦³¤H¶i±Ð«Ç®É
¥þÅé°_¥ß
·q§
¥þÅ駤¤U
================================
Private Sub Worksheet_Calculate()
If ±ø¥ó§PÂ_ = True Then
¡@Application.EnableEvents = False
¡@Call RecordPrice
¡@Application.EnableEvents = True
End If
¦³¤H¶i±Ð«Ç®É
¦pªG¶i¨Óªº¬O¦Ñ®v
¥þÅé°_¥ß
·q§
¥þÅ駤¤U
End Sub

°²³]¶i¨Óªº¦³¢°¢¯¢¯­Ó¤H¦¸¡A¦Ó¦Ñ®v¥u¦³¢´¤H¡A¸Õ·Q¬Ý¬Ý¨âºØª¬ªp®t§O¦h¤Ö¡H¡H¡H¡@
¡@
¡@

TOP

¦^´_ 8# c_c_lai


    C¤j§Ú¤F¸Ñ¤F

TOP

¦^´_ 7# ÂŤÑÄR¦À
§A¦Û¤v¥ý´ú¸ÕÆ[¹î¦³¦ó®t²§¡H
µª®×¬O¤@¼Ëªº¡C
®t§O¶È¦b©ó§A¬~¾þ®É±N´«¬~¦çªA©ñ¦bª×«Ç»P¨Æ¥ý®³¶i¯D«Ç
¦³¦ó®t§O¡H

TOP

¦^´_ 6# c_c_lai

C¤j§Ú¤]¦³½Ð±Ð¥L¡A¥t¥~
Private Sub Worksheet_Calculate()
        Application.EnableEvents = False.............©Ò¥H¬O¥[¦b³oÃä
        Call RecordPrice
        Application.EnableEvents = True..............ÁÙ¦³³oÃä¶Ü??
        End Sub
..............................................................................................................................................................................

Sub RecordPrice()
Dim WR As Long
Dim I As Byte


If Range("E2") < 1 Then Exit Sub

WR = Range("A1").End(xlDown).Row + 1
If (WR = 3) Or _
   ((Second(Range("A2")) Mod 5) = 1) Then
    Application.EnableEvents = False.................³oÃä
    Cells(WR, 1).Resize(, 4) = [A2:D2].Value
   Application.EnableEvents = True...................ÁÙ¦³³oÃä
   End If
End Sub

¥[¦b¤W­±³o¨â­Ó¦a¤è¦³¬Æ»ò¤£¦P??

TOP

¦^´_ 5# ÂŤÑÄR¦À
§AÀ³¸Ó½Ð±Ð stillfish00 ¤j¤jªº¡C
  1. Sub RecordPrice()
  2.     Dim WR As Long
  3.     Dim I As Byte

  4.     If Range("E2") < 1 Then Exit Sub
  5.     Application.EnableEvents = False
  6.     .
  7.     .
  8.     .
  9.     Application.EnableEvents = True
  10. End Sub
½Æ»s¥N½X

TOP

¦^´_ 3# c_c_lai

C¤j´ú¸Õ«á¤@¼Ë°ïÅ|ªÅ¶¡¤£¨¬¡A§Ú¬Q¤Ñ¬O¥Î2#ªº¤èªk¡A¥ÎApplication.EnableEvents¥h¸Ñ¨Mªº¡A¦ý¬O¹ï©ó¥[¦b¨º¸Ì¤£¬O«Ü²M·¡¡AC¤j¥i¥H¬Ý¬Ý4#¦Aµ¹§Ú¤@¨Ç·N¨£

TOP

¦^´_ 2# stillfish00
S¤j§A¦n¤p§Ì¦³¨â­ÓºÃ°Ý¸ò§A½Ð±Ð¤@¤U

1.§Úµ{¦¡¸Ì­±¨S¦³WorkSheet_Change()¡A
¦ý¦³Private Sub Worksheet_Calculate()
        Application.EnableEvents = False.............©Ò¥H¬O¥[¦b³oÃä
        Call RecordPrice
        Application.EnableEvents = True..............ÁÙ¦³³oÃä¶Ü??
        End Sub

2.S¤jÁÙ¨S»¡¤§«e§Ú¬O¥[¦b
Sub RecordPrice()
Dim WR As Long
Dim I As Byte


If Range("E2") < 1 Then Exit Sub

WR = Range("A1").End(xlDown).Row + 1
If (WR = 3) Or _
   ((Second(Range("A2")) Mod 5) = 1) Then
    Application.EnableEvents = False.................³oÃä
    Cells(WR, 1).Resize(, 4) = [A2:D2].Value
   Application.EnableEvents = True...................ÁÙ¦³³oÃä
   End If
End Sub

§Ú¥[§¹«á´N¥i¥H°õ¦æ¤F¡A½Ð±ÐS¤j§Ú²Ä¤@­Ó®aªº¦a¤è¹ï¶Ü??¦pªG¹ï¡A¨º¸ò²Ä¤G­Ó¥[ªº¦a¤è°õ¦æ°_¨Ó·|¦³¤°»ò¤£¦P©O?

TOP

¦^´_ 1# ÂŤÑÄR¦À
  1. WR = Range("A1").End(xlDown).Row + 1
½Æ»s¥N½X
½Ð§ï¦¨
  1. WR = Range("A" & Rows.Count).End(xlUp).Row + 1
½Æ»s¥N½X
¸Õ¸Õ¬Ý¡C

TOP

        ÀR«ä¦Û¦b : ¡i®É¶¡¦pÆp¥Û¡j®É¶¡¹ï¤@­Ó¦³´¼¼zªº¤H¦Ó¨¥¡A´N¦pÆp¥Û¯ë¬Ã¶Q¡F¦ý¹ï·M¤H¨Ó»¡¡A«o¹³¬O¤@§âªd¤g¡A¤@ÂI»ù­È¤]¨S¦³¡C
ªð¦^¦Cªí ¤W¤@¥DÃD