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

[µo°Ý] ¦¹¥¨¶°¬°¦ó¿ù??

¶W¹L 5­Ó ¥H¤W?
¨º´NÃä³B²zÃä­p¼ÆÅo:
luhpro µoªí©ó 2013-8-3 10:29


¬O§_·|¤Ó®øÏä¨t²Î¸ê·½??

TOP

¦^´_ 11# t8899
¬Û¤ñµ{¦¡¤¤¨ä¥L³¡¤Àªº°Ê§@¨Ó»¡,

³o¥u¬O±N¬Y­ÓÅܼưµ ¥[1 ªº°Ê§@,

¸ê·½®ø¯Ó´X¥G¥i¥H¤£­p.

TOP

¦^´_  t8899
¬Û¤ñµ{¦¡¤¤¨ä¥L³¡¤Àªº°Ê§@¨Ó»¡,

³o¥u¬O±N¬Y­ÓÅܼưµ ¥[1 ªº°Ê§@,

¸ê·½®ø¯Ó´X¥G¥i¥H¤£­p ...
luhpro µoªí©ó 2013-8-3 10:58

©êºp¡A¦A¥´ÂZ¤@¤U
±ø¥ó·Q§ï¦¨
¥u¦³ Range("f2:F54")  ÅܰʶW¹L 1% «h±ø¥ó¦¨¥ß(Range("f2:F54") ¬°DDE³sµ²)
¨Ò¦p 100 Åܦ¨ 101 ©Î 99 «h¦¨¥ß

TOP

©êºp¡A¦A¥´ÂZ¤@¤U
±ø¥ó·Q§ï¦¨
¥u¦³ Range("f2:F54")  ÅܰʶW¹L 1% «h±ø¥ó¦¨¥ß(Range("f2:F54") ¬°DDE³s ...
t8899 µoªí©ó 2013-8-4 09:57

§ï¦¨³o­ÓÀ³¸Ó¤£§xÃø°Ú:

If Int(xx - xx.Offset(, -1)) >= 0.01 And Range("I1").Value = 1 Then

TOP

¥»©«³Ì«á¥Ñ t8899 ©ó 2013-8-4 22:27 ½s¿è
§ï¦¨³o­ÓÀ³¸Ó¤£§xÃø°Ú:

If Int(xx - xx.Offset(, -1)) >= 0.01 And Range("I1").Value = 1 Then
luhpro µoªí©ó 2013-8-4 21:44

Range("f2:F54")  ÅܰʶW¹L 1%
¬O¦ÛÄæ¸ò¦ÛÄæ¤ñ¸û ¤£¬O¸ò EÄæ(xx.Offset(, -1)) ¤ñ¸û
§YÅÜ°Ê«á-ÅÜ°Ê«e >1%©Î<1%  Åã¥Ü¬Û´îªº­È BOX(¶·Åã¥Ü¼W¥[ÁÙ¬O´î¤Ö)

¥t¥~¤U­±³o¬qµ{¦¡½XÅã¥Üªº¹ï¸Ü²°¬°¦ó¨S´«¦æ??

Dim sStr2$
Dim ZZ As Range
      sStr2 = ""
   For Each ZZ In Range("c2:c111")
    If Not IsError(ZZ) Then
      If ZZ > ZZ.Offset(, 26) * 1.01 Or ZZ < ZZ.Offset(, 26) * 0.99 And Range("Q26").Value = 1 And flag = True Then
        If sStr2 <> "" Then sSt2r = sStr2 & Chr(10)
        sStr2 = sStr2 & "­ÓªÑ»P¤W¤@½L===> " & Cells(ZZ.Row, 2).Value & "=====> " & ZZ.Value
        
        
        ' Exit For
      End If
    End If
  Next
  If sStr2 <> "" Then CreateObject("Wscript.shell").Popup sStr2, 2, "Auto Closed MsgBox", 64
    Range("Q26").Value = 2
        Application.OnTime Now + TimeValue("00:00:15"), "FFF"

TOP

¥»©«³Ì«á¥Ñ luhpro ©ó 2013-8-4 22:40 ½s¿è
Range("f2:F54")  ÅܰʶW¹L 1%
¬O¦ÛÄæ¸ò¦ÛÄæ¤ñ¸û ¤£¬O¸ò EÄæ(xx.Offset(, -1)) ¤ñ¸û
§YÅÜ°Ê«á-ÅÜ°Ê«e  ...
t8899 µoªí©ó 2013-8-4 22:24

Excel ¨Ã¤£¯à§ì¨ú¥ô¤@Àx¦s®æ©ó "ÅÜ°Ê«e" ªº­È,
°£«D§A¨Æ¥ý§â¥¦¦s°_¨Ó,
©Ò¥H§A¥i¥H¦Ò¼{¤ñ¸û§¹¥ß¨è§â¥Ø«eªº­È¦s©ñ¨ì¸Ó¦C¬YÄæ(©Î¬O°}¦C, Dictionary...)¤W,
¨ì¤U¦¸»Ý­n®É¦A±N¥Ø«eªº­È»P¸ÓÄæ(©Î¬O°}¦C, Dictionary...)°µ¤ñ¸û.

¦Ü©ó§A»¡ªº¨S¦³´«¦æ...
If sStr2 <> "" Then sSt2r = sStr2 & Chr(10)
¬õ¦rªº 2r »P r2 ¤£¦P,
³o´N¤£¬O sStr2 ÅܼƤF³á.

TOP

Excel ¨Ã¤£¯à§ì¨ú¥ô¤@Àx¦s®æ©ó "ÅÜ°Ê«e" ªº­È,
°£«D§A¨Æ¥ý§â¥¦¦s°_¨Ó,
©Ò¥H§A¥i¥H¦Ò¼{¤ñ¸û§¹¥ß¨è§â¥Ø«e ...
luhpro µoªí©ó 2013-8-4 22:39

§Ú¤W­±ªº´N¬O¦p¦¹¼gªº,¦]¬°¦³or§PÂ_
¦b¿é¥X®É¡A¦p¦ó§ï¬°
1. ¦pZZ > ZZ.Offset(, 26) * 1.01 ,«h ¿é¥X "º¦" ¤Î ZZ »P ZZ.Offset(, 26) * 1.01 ¤§®t
2. ¦pZZ < ZZ.Offset(, 26) * 1.01 ,«h ¿é¥X "¶^" ¤Î ZZ »P ZZ.Offset(, 26) * 1.01 ¤§®t
================================================
¦¹¥y Application.OnTime Now + TimeValue("00:00:15"), "ccc" , ¬O§_·|¶] AAA,BBB ??

Sub AAA()
Sheet4.Range("Q1").Value = 1
End Sub
------------------
Sub BBB()
Sheet4.Range("Q12").Value = 1
End Sub
------------------
Sub CCC()
Sheet4.Range("Q20").Value = 1
End Sub
=============================================
°õ¦æ¥¨¶°®É¡A¦p¦ó¤£¦û¥Î¥Ø«e¤u§@ªíµøµ¡ ??
°²¦pµe­±¦b sheet4 ¤W,°õ¦æ¥H¤U¥¨¶°
¦p¦óÅý¥¦¤£¤Á¨ìsheet3,¤@ª½°±¦bsheet4 ¤W

Sub FFF()
Sheets("Sheet3").Select
    Range("C2:C111").Select
    Selection.Copy
    Range("AC2").Select
'¶K¤W­È»P¼Æ¦r®æ¦¡
    Selection.PasteSpecial Paste:=xlPasteValuesAndNumberFormats, Operation:= _
        xlNone, SkipBlanks:=False, Transpose:=False
                    Range("E2").Select
              End Sub

TOP

¥»©«³Ì«á¥Ñ t8899 ©ó 2013-8-5 07:34 ½s¿è

¤U­±¦¹¬q¤u§@ªí¦³ÅÜ°Ê¡A¦ý±ø¥ó¥¼¹F¨ì(flag=false)¡A³Ì«á¤@¦æ Application.OnTime Now + TimeValue("00:00:15"), "DDD"¤´·|°õ¦æ ??
©ñªº¦ì¸m¤£¹ï??­nÂ\¦b¨º¸Ì?
Private Sub Worksheet_Calculate()
  Dim sStr$
  Dim xx As Range
  sStr = ""
  For Each xx In Range("AG2:AG50")
    If Not IsError(xx) Then
      If xx > xx.Offset(, -1) And Range("Q24").Value = 1 And flag = True Then
        If sStr <> "" Then sStr = sStr & Chr(10)
        sStr = sStr & "³æ¶q===> " & Cells(xx.Row, 2).Value & "=====> " & xx.Value
        ' Exit For
      End If
    End If
  Next
  If sStr <> "" Then CreateObject("Wscript.shell").Popup sStr, 3, "Auto Closed MsgBox", 64
    Range("Q24").Value = 2
        Application.OnTime Now + TimeValue("00:00:15"), "DDD"
end sub
---------------------------------------------------------
Sub DDD()
Sheet4.Range("Q24").Value = 1
End Sub

TOP

¥»©«³Ì«á¥Ñ luhpro ©ó 2013-8-6 23:30 ½s¿è
§Ú¤W­±ªº´N¬O¦p¦¹¼gªº,¦]¬°¦³or§PÂ_
¦b¿é¥X®É¡A¦p¦ó§ï¬°
1. ¦pZZ > ZZ.Offset(, 26) * 1.01 ,«h ¿é¥X "º¦" ¤Î ZZ »P ZZ.Offset(, 26) * 1.01 ¤§®t
2. ¦pZZ < ZZ.Offset(, 26) * 1.01 ,«h ¿é¥X "¶^" ¤Î ZZ »P ZZ.Offset(, 26) * 1.01 ¤§®t
t8899 µoªí©ó 2013-8-5 04:35

¦]¬°¨S¦³§A¹ê»Úªºµ{¦¡¤º®e,
©Ò¥H¥u¦n®³§A¤§«eªºµ{¦¡¨Ó­×§ï,
§A¦A°Ñ·ÓµÛÀ³¥Î.
  1. Private Sub Worksheet_Calculate()
  2.   Dim lCount As Long, lDir As Long
  3.   Dim sStr$
  4.   Dim ZZ As Range
  5.   Dim rRoF()

  6.   rRoF = Array("¶^", "º¦")
  7.   sStr = ""
  8.   lCount = 0
  9.   For Each ZZ In Range("f2:F54")
  10.     If Not IsError(ZZ) Then
  11.       lDir = ZZ - ZZ.Offset(, -1)
  12.       If Abs(lDir) > 0.01 And Range("I1").Value = 1 Then
  13.         If sStr <> "" Then sStr = sStr & Chr(10)
  14.         sStr = sStr & "===> " & Cells(ZZ.Row, 2).Value & "=====> " & rRoF(-(lDir > 0)) & " " & Abs(lDir)
  15.         lCount = lCount + 1
  16.       End If
  17.     End If
  18.   Next
  19.   If sStr <> "" And lCount > 5 Then CreateObject("Wscript.shell").Popup sStr, 15, "Auto Closed MsgBox", 64
  20. End Sub
½Æ»s¥N½X
¦¹¥y Application.OnTime Now + TimeValue("00:00:15"), "ccc" , ¬O§_·|¶] AAA,BBB ??

¤£·|, §A¤w¸g«ü©w¥¦¥h¶] ccc ¤F,
°£«D§A¦b ccc ¤¤¦³¥[¤W Call AAA ¤Î Call BBB.

°õ¦æ¥¨¶°®É¡A¦p¦ó¤£¦û¥Î¥Ø«e¤u§@ªíµøµ¡ ??

±N¤£·Q¥X²{¤Á´«°Ê§@ªº¦a¤èªº .select ®³±¼,(¬Û¹ïªº¦³ Selection ªº¦a¤è¤]­n­×§ï)
©Î¬O¦b¤£·Qµe­±Åܰʪº°Ï¶¡¥H
Application.EnableEvents = False ¤Î
Application.EnableEvents = true ¥]ÂÐ.


¤U­±¦¹¬q¤u§@ªí¦³ÅÜ°Ê¡A¦ý±ø¥ó¥¼¹F¨ì(flag=false)¡A³Ì«á¤@¦æ Application.OnTime Now + TimeValue("00:00:1 ...
t8899 µoªí©ó 2013-8-5 07:21

§ï¦¨ :
If flag Then Application.OnTime Now + TimeValue("00:00:15"), "DDD"

TOP

¥»©«³Ì«á¥Ñ t8899 ©ó 2013-8-7 06:46 ½s¿è
luhpro µoªí©ó 2013-8-6 23:25

±N¤£·Q¥X²{¤Á´«°Ê§@ªº¦a¤èªº .select ®³±¼,(¬Û¹ïªº¦³ Selection ªº¦a¤è¤]­n­×§ï)   

.select ®³±¼´N¨S¿ìªk°õ¦æ§Ú·Q­n°µ³o«ü¥Oªº°Ê§@
ÁÙ¬O¦³¨ä¥L«ü¥O¥i´À´«??

©Î¬O°õ¦æ«e°O¦í"¥Ø«esheet"¡A°õ¦æ§¹¦Û°Ê¦^­ìsheet ªº«ü¥O?
©Î¬O¦b¤£·Qµe­±Åܰʪº°Ï¶¡¥H
Application.EnableEvents = False ¤Î
Application.EnableEvents = true ¥]ÂÐ.   
Application.ScreenUpdating=False
Application.ScreenUpdating=True

¸Õ¹L¬ÒµL®Ä

TOP

        ÀR«ä¦Û¦b : ¨C¤ÑµL©Ò¨Æ¨Æ¡A¬O¤H¥Íªº®ø¶OªÌ¡A¿n·¥¡B¦³¥Î¤~¬O¤H¥Íªº³Ð³yªÌ¡C
ªð¦^¦Cªí ¤W¤@¥DÃD