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

¦p¦ó¨Ï¥Î°}¦C¨ì¤£¦Psheet§ì¨ú¸ê®Æ

¦p¦ó¨Ï¥Î°}¦C¨ì¤£¦Psheet§ì¨ú¸ê®Æ

¦U¦ì¤j¤j,
½Ð°Ý¸Ó¦p¦ó¨Ï¥Î°}¦C¨ì¤£¦Psheet§ì¨ú¸ê®Æ
Àɮצpªþ¥ó
§ó·s1.rar (27.39 KB)

¦^´_ 1# yueh0720
¬O³o¼Ë¶Ü?
  1. Private Sub Update_Click()
  2.     Dim y&, xR As Range, uP$, uF$
  3.     xRange = Array("$C$5", "$D$10", "$J$21", "$J$26")
  4.     uP = ThisWorkbook.Path & "\"
  5.     Application.ScreenUpdating = False
  6.     For Each xR In Range([A2], [A65536].End(3))
  7.         If Dir(uP & xR) = "" Then GoTo 101
  8.         uF = "'" & uP & "[" & xR & "]Sheet1'!"
  9.         j = 2
  10.         For Each xC In xRange
  11.             xR(1, j) = "=" & uF & xC
  12.             j = j + 1
  13.         Next
  14. 101:
  15.     Next
  16. End Sub
½Æ»s¥N½X
{...} ªí¥Ü»Ý­n¥Î CTRL+SHIFT+ENTER ¤TÁä¿é¤J¤½¦¡

TOP

ML089 ¤j,
¨S¿ìªk~¤À­¶µLªk½Æ»s

TOP

¦^´_ 3# yueh0720
  1. Private Sub Update_Click()
  2.     Dim y&, xR As Range, uP$, uF$
  3.     xRange = Array("Sheet1'!C5", "Sheet1'!D10", "Sheet1'!J21", "Sheet1'!J26", _
  4.                    "²Ä¤T­¶'!C5", "²Ä¤T­¶'!D10", "²Ä¤T­¶'!J21", "²Ä¤T­¶'!J26", _
  5.                    "²Ä¤C­¶'!C5", "²Ä¤C­¶'!D10", "²Ä¤C­¶'!J21", "²Ä¤C­¶'!J26")
  6.    
  7.     uP = ThisWorkbook.Path & "\"
  8.     Application.ScreenUpdating = False
  9.     For Each xR In Range([A2], [A65536].End(3))
  10.         If Dir(uP & xR) = "" Then GoTo 101
  11.         uF = "'" & uP & "[" & xR & "]"
  12.         j = 2
  13.         For Each xC In xRange
  14.             xR(1, j) = "=" & uF & xC
  15.             j = j + 1
  16.         Next
  17. 101:
  18.     Next
  19. End Sub
½Æ»s¥N½X
{...} ªí¥Ü»Ý­n¥Î CTRL+SHIFT+ENTER ¤TÁä¿é¤J¤½¦¡

TOP

¦^´_ 3# yueh0720

¦pªG§A¹ï¨º¼h¼Ó¦³·N¨£®É¡A½Ð«ö¸Ó¼h¼Ó¤U¤èªº¦^ÂСA³o¼Ë¨t²Î¤~·|³qª¾¡C
{...} ªí¥Ü»Ý­n¥Î CTRL+SHIFT+ENTER ¤TÁä¿é¤J¤½¦¡

TOP

¦^´_ 1# yueh0720
  1. Private Sub Update_Click()
  2. Dim y&, xR As Range, uP$, uF$, Ar(), Sh As Worksheet
  3. uP = ThisWorkbook.Path & "\"
  4. Application.ScreenUpdating = False
  5. With Sheet1
  6. For Each xR In .Range(.[A2], .[A65536].End(3)).SpecialCells(xlCellTypeConstants)
  7.     If Dir(uP & xR) = "" Then GoTo 101
  8.     With Workbooks.Open(uP & xR)
  9.        For Each Sh In .Sheets
  10.        With Sh
  11.          ReDim Preserve Ar(s)
  12.          Ar(s) = Array(.[C5].Value, .[D10].Value, .[J21].Value, .[J26].Value)
  13.          s = s + 1
  14.        End With
  15.        Next
  16.     .Close 0
  17.     End With
  18. xR.Offset(, 1).Resize(s, 4) = Application.Transpose(Application.Transpose(Ar))
  19. Erase Ar: s = 0
  20. 101: Next
  21. End With
  22. End Sub
½Æ»s¥N½X
¾Ç®üµL²P_¤£®¢¤U°Ý

TOP

¦^´_ 5# ML089


    ¤F¸Ñ,ÁÂÁ§iª¾

TOP

        ÀR«ä¦Û¦b : ¥¬¬I¦p¼½ºØ¡A¥HÅw³ß¤ß´þ¼íºØ¤l¡A¤~·|µoªÞ¡C
ªð¦^¦Cªí ¤W¤@¥DÃD