G
Greg
Hi, I am using scripting to get the time and date off some pictures.
I am having a problem the date/time properties missing the seconds
component. Formation the data as hh:mm:ss does not help.
Using windows 7, excel 2010
Name Size Item type Date modified
P1030001.JPG 5.31 MB JPG File 10/11/2010 8:11
Date created Date accessed Date taken
10/11/2010 8:11 22/10/2010 12:00 AM ‎11/‎10/‎2010 â€â€Ž8:11 AM
Sub Extract_file_details()
'http://www.microsoft.com/technet/scriptcenter/guide/sas_fil_lunl.mspx?
mfr=true
Const oNum = 30
Dim iFound As Integer
Dim arrHeaders(oNum) 'max 279 cols
Dim i As Integer
Dim objShell As Object
Dim objFolder As Object
Dim strFileName As Variant
Dim x As Integer
Set objShell = CreateObject("Shell.Application")
Set objFolder = objShell.Namespace("F:\DCIM\103_PANA") 'change to
suite
For i = 0 To oNum '279
arrHeaders(i) = objFolder.GetDetailsOf(objFolder.Items, i)
Cells(1, i + 1) = arrHeaders(i)
Next
x = 1
For Each strFileName In objFolder.Items
x = x + 1
Cells(x, 1).Select
For i = 0 To oNum '266 best 279
Cells(x, i + 1).Value = objFolder.GetDetailsOf(strFileName, i)
Next
Next
End Sub
Thank you for any help in advance
I am having a problem the date/time properties missing the seconds
component. Formation the data as hh:mm:ss does not help.
Using windows 7, excel 2010
Name Size Item type Date modified
P1030001.JPG 5.31 MB JPG File 10/11/2010 8:11
Date created Date accessed Date taken
10/11/2010 8:11 22/10/2010 12:00 AM ‎11/‎10/‎2010 â€â€Ž8:11 AM
Sub Extract_file_details()
'http://www.microsoft.com/technet/scriptcenter/guide/sas_fil_lunl.mspx?
mfr=true
Const oNum = 30
Dim iFound As Integer
Dim arrHeaders(oNum) 'max 279 cols
Dim i As Integer
Dim objShell As Object
Dim objFolder As Object
Dim strFileName As Variant
Dim x As Integer
Set objShell = CreateObject("Shell.Application")
Set objFolder = objShell.Namespace("F:\DCIM\103_PANA") 'change to
suite
For i = 0 To oNum '279
arrHeaders(i) = objFolder.GetDetailsOf(objFolder.Items, i)
Cells(1, i + 1) = arrHeaders(i)
Next
x = 1
For Each strFileName In objFolder.Items
x = x + 1
Cells(x, 1).Select
For i = 0 To oNum '266 best 279
Cells(x, i + 1).Value = objFolder.GetDetailsOf(strFileName, i)
Next
Next
End Sub
Thank you for any help in advance