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

[µo°Ý] ¦p¦ó¨Ì·Ó²M³æ¶¶§Ç¶}ÀÉ«á½s¿èÀÉ®×

[µo°Ý] ¦p¦ó¨Ì·Ó²M³æ¶¶§Ç¶}ÀÉ«á½s¿èÀÉ®×

¦U¦ì¥ý¶i¦n¡A
§Ú¦³¤@²Õ²M³æ¬O¦s¦bAªº¦ì¸m¤W¡A¥Ø«e§Ú¤wª¾¹D­n¦p¦ó¨Ï¥ÎVBA¨Ì§Ç¶}±ÒÀɮסA
¦ý§Ú§Æ±æ¶}±ÒÀɮ׫á¯à¦b¶}±Òªº³o­ÓÀɮפW°õ¦æ¥t¤@­ÓVBAµ{¦¡(¤ñ¦p­pºâÁ`©M)¡A
¤§«á±Nµ²ªG¦^¶Ç¦^­ì©l²M³æªº¸ê®Æ¡A³o­Ó³¡¤À¤£²M·¡¦p¦ó¾Þ§@¡C
³Â·Ð¦U¦ì«e½úÀ°¦£¡AÁÂÁ¡C

¨Ì·Ó²M³æ¶¶§Ç¶}±ÒÀÉ®×.rar (12.49 KB)

¦^´_ 1# linlin00


    Workbooks.Open­n§¹¾ãªº¸ô®|©MÀɦW¡A¦ý Workbooks("¬¡­¶Ã¯¦WºÙ")?¤£¥Î¸ô®|¡A?¥u­nÀɦW´N¥i¥H
¦p¤Uµ{¦¡¸ÑÄÀ¡G
  1.     For i = 1 To 2
  2.         fpath = ThisWorkbook.ActiveSheet.Cells(i, 1) '¸ô®| "C:\Documents and Settings\Administrator\My Documents\"
  3.         ffile = ThisWorkbook.ActiveSheet.Cells(i, 2) 'ÀɦW "vbatest2.xls"
  4.         Workbooks.Open (fpath & ffile)
  5.         Workbooks("ffile").Sheets ("¤u§@ªí1")...
  6.         ...
  7.         ...¨ä¤º®e¦Û¦æ¶ñ¸É
  8.         ...
  9.         ...
  10.         Workbooks("ffile").Close True
  11.     Next
½Æ»s¥N½X

TOP

¦^´_ 2# lpk187
·PÁ¦^´_!
§Ú¥ý¾Þ§@¸Õ¸Õ¬Ý

TOP

¦^´_ 2# lpk187
«D±`·PÁ¡A§Ú§ËÀ´¤F!

TOP

        ÀR«ä¦Û¦b : ¶¢¤HµL¼Ö½ì¡A¦£¤HµL¬O«D¡C
ªð¦^¦Cªí ¤W¤@¥DÃD