08/03/2012, 16:21
Command0 isimli bir buton oluşturun aşağıdaki kodları formunuz yapıştırın. Msgbox ile gelen değer Son Değiştirilme Tarihidir.
Option Compare Database
Sub dosya_veya_klasor_ozellikleri()
Dim ShellApp As Object, Parse As Object
Dim f As Variant, d As Variant, s As Long
Dim str1 As String * 25
Dim str2 As String
On Error Resume Next
f = "C:\Users\yasin\Desktop\Kargo\"
d = "pd.dll"
Set ShellApp = CreateObject("Shell.Application")
Set Parse = ShellApp.NameSpace(f).ParseName(d)
For s = 0 To 50
str1 = ShellApp.NameSpace(f).GetDetailsOf(d, s)
str2 = ShellApp.NameSpace(f).GetDetailsOf(Parse, s)
If x <> InStr(1, str1, "Değiştirme") Then MsgBox Format(CVDate(str2), "DD.MM.YYYY") 'Debug.Print str1 & " = " & str2
Next
If err Then MsgBox err.Description
End Sub
Private Sub Command0_Click()
Call dosya_veya_klasor_ozellikleri
End Sub