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

·Q½Ð±Ð-¦b³]©wªº¤é´Á¦Û°Ê°õ¦æ¥¨¶°

·PÁÂGBKEEª©¤j´£¨Ñ§ó²¼äªº¼gªk,
³o¼Ë¥i¥H¤Ö¥´«Ü¦h¦r¤F,
ÁÂÁÂ.....

TOP

¦^´_ 25# ¤TÄ_
  1. Sub EX()
  2. If Date = "2010/10/20" Then
  3. Application.OnTime "21:15:00", "macro1"
  4. ElseIf Date = "2010/10/21" Then
  5. Application.OnTime "21:17:20", "macro2"
  6. ElseIf Date = "2010/10/22" Then
  7. Application.OnTime "21:26:00", "macro3"
  8. End If
  9. End Sub
½Æ»s¥N½X

TOP

·PÁÂGBKEEª©¤j¼ö¤ß¦^ÂÐ,
§Ú¸Õ¹L,¥i¥H¸Ñ¨M¤F
¤£¹L§Ú§ï¦¨:
Sub EX()
If Date = "2010/10/20" Then
Application.OnTime "2010/10/20 21:15:00", "macro1"

ElseIf Date = "2010/10/21" Then
Application.OnTime "2010/10/21 21:17:20", "macro2"

ElseIf Date = "2010/10/22" Then
Application.OnTime "2010/10/22 21:26:00", "macro3"

End If
End Sub
³o¼Ë¤]¦æ,­«¶}Àɮפ§«á,¤£·|¦A¥h°õ¦æ¬Q¤Ñªºmacro¤F(§Ú¦³§ï¨t²Î¤é´Á´ú¸Õ¹L),
¦]¬°§Ú«Ü¦h®É¶¡¬O¤£¤@¼Ëªº,³o¼Ë¤ñ¸û¦n§ï,
ÁÂÁ§A,¤S¦h¾Ç¤F¤@©Û......

TOP

¦^´_ 23# ¤TÄ_
¹J¨ì¸ê®Æ§R°£µLªk´_­ì®É Ãö³¬Àɮ׮ɿï¾Ü ¤£­n¦sÀÉ ­«·s¶}±ÒÀÉ®× ´N¥i¥H
  1. Sub Ex()
  2.     Dim Macro$
  3.     If Date = "2010/10/19" Then
  4.         Macro = "Macro1"
  5.     ElseIf Date = "2010/10/20" Then
  6.         Macro = "Macro2"
  7.     ElseIf Date = "2010/10/21" Then
  8.         Macro = "Macro3"
  9.     End If
  10.     Application.OnTime "17:26:00", Macro
  11. End Sub
½Æ»s¥N½X

TOP

¤£¦n·N«ä,§Úµo²{¤@­Ó°ÝÃD,§ÚªºVBA¬O³o¼Ë¼g:
Sub EX()
Application.OnTime "2010/10/19 17:26:00", "macro1"
Application.OnTime "2010/10/20 17:26:00", "macro2"
Application.OnTime "2010/10/21 17:26:00", "macro3"
End Sub
§Ú¬Q¤Ñ°õ¦æ¥¿±`,¦]¬°¬Q¤Ñ¬O10¤ë19¤é,10¤ë20¤éÁÙ¨S¨ì,©Ò¥Hmacro2¸òmacro3¤£·|IJµo,
¥i¬O¤µ¤Ñ¦A¥´¶}ÀÉ®×,¦A°õ¦æEX,
µ²ªGµo²{¬Q¤Ñªºmacro1¤S¦A°õ¦æ¤F¤@¦¸,
¦Ó§â¤µ¤Ñªº¸ê®Æ³£»\±¼¤F,
³o....³o.....³o¸Ó«ç»ò¿ì?
­n«ç»ò¼g¤~ªí¥Ü¹L¤F10¤ë19¤é¤§«á,´N¤£·|¦A¦¸°õ¦æmacro1©O?
ÁÂÁÂ.....

TOP

¦^´_ 21# ¤TÄ_
expression.OnTime(EarliestTime, Procedure, LatestTime, Schedule)
OnTime¥²­n¤Þ¼Æ
EarliestTimeIJµo®É¶¡
Procedureµ{§Ç¦WºÙ
¾Ç®üµL²P_¤£®¢¤U°Ý

TOP

·PÁÂGBKEEª©¤j,§Ú¬O³o¼Ë¼g°Õ:
Sub macro1()
Application.OnTime "2010/10/19 22:55:30"
MsgBox Format(Now, "YYYY/M/D  H:M:ss")
End Sub
µM«á§Úª½±µ°õ¦æmacro1,
³o¼Ë¨S¿ìªk°õ¦æ...
¤£¹L¨SÃö«Y,§Ú´N©ñ¦bSub EX()´N¥i¥H¤F,
ÁÂÁÂ.

TOP

¦^´_ 19# ¤TÄ_
¤£¹LApplication³o¤@¥y¤£¯àª½±µ©ñ¦bmacro1¸Ì
§A¦p¦ó¼g PO ¤W¬Ý¬Ý

TOP

·PÁÂoobird,GBKEEª©¤j¼ö¤ß¸Ñ´b,
Sub Ex()
Application.OnTime "2010/10/20 09:00", "Macro1"
End Sub
¤w¸g¸Õ¹L§¹¥þ¥i¦æ¤F,
Sub auto_open()¤]¥i¥H,
§Úµo²{ÀH«KSub¤°»ò³£¦æ,sub aa()¤]¥i¥H
­«ÂI¬O¤é´Áªºªí¥Ü¤èªk,­n¥Î2010/10/19
§Ú¤§«e¤@ª½¥Î2010,10,19....©Ò¥H¤£¦æ
¤£¹LApplication³o¤@¥y¤£¯àª½±µ©ñ¦bmacro1¸Ì
¥¦»¡....½sĶ¿ù»~,¤Þ¼Æ¤£¬°¿ï¾Ü©Ê(optional).....
¶â...ÁÙ¦³«Ü¦h­n¾Çªº,
ÁÂÁ§A­Ì.

TOP

¦^´_ 17# oobird
¦hÁ«ü¥¿ ¤w­×¥¿
¦^´_ 16# ¤TÄ_
¶K¦bModule2  ª`·N ¦pModule1¸ÌÁÙ¦³¬Û¦P¦WºÙ Sub Macro1() ®É
»Ý«ü©ú¬O­þ¤@­Ó¼Ò²Õ  Application.OnTime "2010/10/20 09:00", "Module2.Macro1"

TOP

        ÀR«ä¦Û¦b : ¦³¦h¤Ö¤O¶q´N°µ¦h¤Ö¨Æ¡A¤£­n¤ß¦sµ¥«Ý¡Aµ¥«Ý¤~·|¸¨ªÅ¡C
ªð¦^¦Cªí ¤W¤@¥DÃD