回復 11#imzues
不好意思: 10樓的程式碼中少給了Date
Sub Idelot()
Dim msFile As String
ChDir ThisWorkbook.Path & "\"
msFile = Dir("DailyIdleLot-" & Format(Date, "yyyy-mm-dd-") & "*")
If msFile <> "" Then
With Workbooks.Open(msFile)
.Sheets("Idle Lot 清單").Copy ThisWorkbook.Sheets(1)
.Sheets("Idle Lot 明細").Copy ThisWorkbook.Sheets(2)
.Close False
End With
End If
End Sub作者: imzues 時間: 2011-10-20 15:58