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

[µo°Ý] Worksheet_Calculate(¦³¿ìªkª¾¹D¬O½ÖÅܰʶÜ?)

[µo°Ý] Worksheet_Calculate(¦³¿ìªkª¾¹D¬O½ÖÅܰʶÜ?)

¥»©«³Ì«á¥Ñ PKKO ©ó 2015-7-20 13:34 ½s¿è

¥Ø«e¤p§Ìªº°ÝÃD¬O¦b©ó
·Q¥ÎWorksheet_Calculate¨Ó¶]dde,¦ýÅܰʪº®É­Ô¬O§_¦³¿ìªk°»´ú¥X¬O½ÖÅÜ°Ê?
¨Ò¦pWorksheet_SelectionChange(ByVal Target As Range),´N¥i¥Hª¾¹Dtarget¬O½Ö
¦p¦¹¤@¨Ó´N¥i¥H¥[§Ö¹B§@³t«×,°w¹ïÅܰʪ̨Ӷ]µ{¦¡´N¦n,¤£»Ý­n­«·s¶]¦^°é

¦bºô¸ô¤W¦³¬Ý¨ìSetLinkOnData ¤èªk,ÁÙ¤£¾å±o¨Ï¥Î¤è¦¡
¦³¤Hª¾¹D¶Ü?
PKKO

¦^´_ 1# PKKO

'¤w¸g§ä¨ì¤U¤è»yªk,¦ý¬OLinkChange¸Ì­±­n¦p¦óª¾¹D¬O­þ­ÓddeÅܧó©O?
  1. Sub TEST()
  2. Links = ActiveWorkbook.LinkSources(xlOLELinks)
  3. If Not IsEmpty(Links) Then
  4.     For I = 1 To UBound(Links)
  5.         ActiveWorkbook.SetLinkOnData Links(I), "LinkChange"
  6.     Next I
  7. Else
  8.   MsgBox "This workbook does not contain any links " & _
  9.              "to other workbooks"
  10. End If
  11. End Sub

  12. Sub LinkChange()
  13.   MsgBox "linked"
  14. End Sub
½Æ»s¥N½X
PKKO

TOP

¦^´_ 2# PKKO


·PıSetLinkOnData »PWorksheet_Calculate ²@µL®t§Oªü,³£¬O°w¹ï§ó·sªº®É­Ô·|IJ°Êµ{¦¡,¥i¬O³£¤£ª¾¹DTarget¬O½ÖÅÜ°Ê

¦U¦ì¤j¤j,¦³¤Hª¾¹D¶Ü?
PKKO

TOP

        ÀR«ä¦Û¦b : ¤Hªº²´·úªø¦b«e­±¡A¥u¬Ý¨ì§O¤Hªº¯ÊÂI¡Aµ·²@¬Ý¤£¨ì¦Û¤vªº¯ÊÂI¡C
ªð¦^¦Cªí ¤W¤@¥DÃD