[attach]30471[/attach]可能我的問題太難懂~所以都沒有人願意回~~~
稍微改良之後~有做出相同功能的用法!!!!給大家參考!!!!
但是目前~還遇到一個問題~~~就是不知道要怎麼改掉~excel內的問題~
Private Sub load檔名()
Dim P As String
P = ThisWorkbook.Path & "\TEST01\"
ActiveSheet.UsedRange.Offset(1).Clear這行要怎麼改~才不會全部的表格內的東西都被刪掉
Get_Picture P
End Sub
Private Sub Get_Picture(ByVal P As String)
Dim Fs, F As Variant
Set Fs = CreateObject("Scripting.FileSystemObject").GETFolder(P)
With ActiveSheet
For Each F In Fs.Files
If F Like "*.jpg" Then '指定副檔名
.Cells(Application.CountA(.[F:F]) + 1, "F") = F.Name
End If
Next
End With
For Each F In Fs.SubFolders
On Error Resume Next
Get_Picture F
Next
End Sub