- ©«¤l
- 5923
- ¥DÃD
- 13
- ºëµØ
- 1
- ¿n¤À
- 5986
- ÂI¦W
- 0
- §@·~¨t²Î
- win10
- ³nÅ骩¥»
- Office 2010
- ¾\ŪÅv
- 150
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW°ò¶©
- µù¥U®É¶¡
- 2010-5-1
- ³Ì«áµn¿ý
- 2022-1-23
|
¥»©«³Ì«á¥Ñ GBKEE ©ó 2014-4-27 10:38 ½s¿è
¦^´_ 8# flyflyduck1
¤@¯ëªº±µ¦¬DEEªº¸ê®Æ ®É¶¡,¶}½L»ù,³Ì°ª»ù,³Ì§C»ù,¦¬½L»ù,¦¨¥æ¶q,¦¨¥æµ§¼Æ
¦b©T©wªºÀx¦s®æ±µ¦¬¼ÆÈ,¨Ï¥ÎªÌ¦b1¤ÀÄÁ,©Î 5¤ÀÄÁ±N¸ê®Æ¾É¤J«ü©wªº¦ì¸m
¥i°Ñ¦Ò¤U±Sheet1¼Ò²Õµ{¦¡ °õ¦æEx()¸Õ¸Õ¬Ý- Option Explicit '±µ¦¬DEEªº¸ê®Æ¥i¨Ï¥Î Worksheet_Calculate
- Private Sub Worksheet_Calculate()
- Static DataLoad_Time As Single 'Static ÃöÁä¦rÀx¦sÅܼÆ
- Static Ar()
- 'Static ³¯z¦¡ ¦bµ{§Ç¼h¦¸¤¤¥Î¨Ó«Å§iÅܼƨðt¸mÀx¦sªÅ¶¡¡C
- '¥H Static ³¯z¦¡«Å§iªºÅܼơA¦bµ{¦¡°õ¦æ´Á¶¡¡A·|¤@ª½«O¯d¤º®e
- '³o¤u§@ªí: °²³]Dee¤½¦¡¦b[B2:I2],¥B¥LÀx¦s®æµL¤½¦¡¦s¦b
- '·N¨ý¥ô¤@Ó Dee¤½¦¡¦³ÅÜ°Ê·|±Ò°Ê³oCalculate¨Æ¥ó
- If DataLoad_Time <> 0 And [b2] - DataLoad_Time > #12:00:59 AM# Then '¦b¤U¤@¤ÀÄÁ¥X²{«á
- Range("B" & Rows.Count).End(xlUp).Offset(1).Resize(1, 8) = Ar '¾É¤J¤W¤@¤ÀÄÁªº¸ê®Æ
- '¥i±µ¤U§@§Anªº¤u§@
- '¥i±µ¤U§@§Anªº¤u§@
- End If
- Ar = [B2:I2].Value '¬ö¿ý¸ê®Æ
- DataLoad_Time = [b2] '¬ö¿ý®É¶¡
- End Sub
- Sub Ex() '³oµ{§Ç¼ÒÀÀDee¤½¦¡¦bSheet2¤WªºÀx¦s®æ,¶i¦ÓIJµoWorksheet_Calculate¨Æ¥ó
- Dim h, L
- h = 50
- L = 40
- With Sheet2.[B2:I2]
- .Cells(1) = Time '¥u¦³¸ê®ÆÅÜ°Ê,¤~·|IJµoWorksheet_Calculate¨Æ¥ó
- .Cells(2) = Int((h - L + 1) * Rnd + L) '50 - 40ªº¶Ã¼Æ
- .Cells(3) = Int((h - L + 1) * Rnd + L)
- .Cells(4) = Int((h - L + 1) * Rnd + L)
- .Cells(5) = Int((h - L + 1) * Rnd + L)
- .Cells(6) = Int((h - L + 1) * Rnd + L)
- .Cells(7) = Int((h - L + 1) * Rnd + L)
- .Cells(8) = Int((h - L + 1) * Rnd + L) '¦pÅÜ°Ê8¦¸´NIJµo8¦¸ªºWorksheet_Calculate¨Æ¥ó
- End With
- Application.OnTime Time + #12:01:00 AM#, "Sheet1.ex"
- Debug.Print Time
- End Sub
½Æ»s¥N½X
|
|