回覆列表
  • 1 # tzdfe4919

    可採用如下程式碼。該檔案儘量不要放在目標資料夾中。執行時,只執行該workbook,其餘關閉。其中的副檔名(xls還是xlsx需要你確認一下,可更改)SubData_Col()Dimmy_PathAsStringApplication.FileDialog(msoFileDialogFolderPicker).Showmy_Path=Application.FileDialog(msoFileDialogFolderPicker).SelectedItems(1)Dimmy_DocAsStringmy_Doc=Dir(my_Path&"\"&"*.xlsx")"手動更改副檔名DimjAsSinglej=1DoWhileLen(my_Doc)<>0Workbooks.Open(my_Path&"\"&my_Doc)ThisWorkbook.Worksheets(1).Cells(j,1)=my_docDimiAsSingleFori=2To12ThisWorkbook.Worksheets(1).Cells(j,i)=Workbooks(2).Worksheets("TEST-RESULT").Cells(29,i)NextWorkbooks(2).Closemy_Doc=Dirj=j+1LoopEndSub

  • 中秋節和大豐收的關聯?
  • 手上有一套尼康D7000想升級全畫幅,D810和D850選哪個?