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

¥ÎEXCEL VBA¬ö¿ý¨C¬íÄÁ°O¿ý¼Æ­È¸õ°Êªº¥¨¶°

¥ÎEXCEL VBA¬ö¿ý¨C¬íÄÁ°O¿ý¼Æ­È¸õ°Êªº¥¨¶°

¥»©«³Ì«á¥Ñ hom770706 ©ó 2018-7-25 20:49 ½s¿è

¤j®a¦n

§Ú¬O§¹¥þ¨S¦³µ{¦¡­I´ºªº·s¤â
³Ìªñ¶}©l¬ã¨sªÑ²¼¥H¤Î·Q¥ÎExcel¬ö¿ý·í¤Uªº¤@¨Ç¼Æ­È
¤è«K½L«á¤ÀªR©M¬ã¨s

¥Ñ©ó§¹¥þ¨S¦³­I´º
©Ò¥H°Ñ¦Òºô¤W§ä¨ìªºµ{¦¡½X¥[¥H­×§ïÄæ¦ì©Î®æ¦¡
¦ýµo²{³£¶]¤£¥X¨Ó

¥Ø«e§Æ±æ¥H¬í¬°³æ¦ì
¤À§O°O¿ý¤U·í®Éªº´X­Ó¼Æ­È(¦p¹Ï©Ò¥Ü)


¦Ó¸õ°Êªº¼Æ¾Ú«h¬O¦b¤u§@ªí1¤¤ªºB4, B10 ¥H¤ÎN13
°Ñ¦Òªºµ{¦¡½X­×§ï«á(¥u¥ý¸ÕµÛ©ñ¤J¤@­Ó¼Æ¾Ú)
  1. Sub Schedule()
  2. DoEvents
  3. If Sheet2.Cells("A2") = 1 Then '·í³o­ÓÄæ¦ì­È¬°1ªº®É­Ô¶}©l¬ö¿ý
  4.     Call record               
  5.     Call timer_Start         
  6. End If
  7. End Sub

  8. Sub timer_Start()
  9. Application.OnTime Now + TimeValue("00:00:01"), "Schedule", Schedule:=True
  10. End Sub

  11. Sub timer_Stop()
  12. On Error Resume Next
  13. Application.OnTime Now + TimeValue("00:00:01"), "Schedule", Schedule:=False
  14. End Sub

  15. Sub record()
  16. Sheet2.Cells("B2") = Sheet2.Cells("B2") + 1
  17. Sheet2.Cells(Sheet2.Cells("B2"), 3) = Sheet1.Cells("B10")
  18. End Sub
½Æ»s¥N½X
ÁٽЦU¦ì¤j¤j¤£§[«ü±Ð
©Î½Ð¤j¤j«ü¾É¦³­þ¤è­±ªº®ÑÄy©Îºô¯¸¥i¥H¬d¸ß©M¾Ç²ß
¸U¤À·PÁÂ

½L«á¤ÀªR¨S¦³¥Î,¥u¦³¦b½L¤¤ÀË°Q¦Û¤wªº¥æ©ö¤~·|¶i¨B
¬ã¨s¦æ±¡«o¤£¬O¬ã¨s¦Û¤w¤w¸g¨«°¾¤F

TOP

¦^´_ 1# hom770706
¦h¦h¥h°Ñ¦Ò§O¤Hªº¼g§@¤Î§l¨ú¥L¤Hªº«ä¸ô¡A
¦p¦¹¤~·|¦³§ó¼e¼sªº¦Û§Ú¥­¥x¡C
°Ñ¦Ò¬Ý¬Ý¬O§_¦p§A»Ý¨D¡C
½L¤¤ DDE ¦sÀÉ»P VBA ªº¹ê»ÚÀ³¥Î½d¨Ò

TOP

¦^´_ 1# hom770706


    «Øij¤j¤j§â¹ê»ÚªºªF¦èªþÀÉ¡A½×¾Â¤º·QÀ°ªº·|¤ñ¸û¦³¤è¦V·P
ªÑ²¼¬ÛÃö¸õ°Êtick¬ö¿ýªº°Q½×À³¸Ó¤]¦³¡A«Øij·j´M¬Ý¬Ý

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