Change Picture Date Taken

Jaye7

Well-known Member
Joined
Jul 7, 2010
Messages
1,060
I would like to create a spreadsheet to change the Date Taken on pictures.
There are around 2000 pictures.

The file location is in column A (C:\Test)
The file name is in column B (Pic1.jpg)
The new Date Taken is in column C (11/3/2018) each one will be different
The new Date Taken Time is in column D (11:22:02) each one will be different
So it loops through the rows and changes the Date Taken to the values in columns C and D
 

Excel Facts

What is the last column in Excel?
Excel columns run from A to Z, AA to AZ, AAA to XFD. The last column is XFD.
Hello,

in my archiv I found a code to modify the FileModified date:

Code:
Sub M_snb()
  MsgBox FileDateTime("G:\OF\__basaal.xlsb")
 
  CreateObject("shell.application").Namespace("G:\OF\").Items.Item("__basaal.xlsb").ModifyDate = DateAdd("d", -2, Now)
 
  MsgBox FileDateTime("G:\OF\__basaal.xlsb")
End Sub

If you check the namespace of a file(i form 1 to 256) you will find the number for "picture taken" and, maybe, you can adopt the code.

regards

(if there is a simple pattern "always add 1 hour" Adobe Lightroom of exif.exe can do it)
 
Upvote 0
again from the archiv:

identify the codes for namespace.items

Code:
Sub Datei_Attribute()
iPath = "c:\temp\"
iFile = "xl-to-wd-book.xlsm"

With CreateObject("shell.application").Namespace(iPath)
    For i = 0 To 255
    if .getDetailsOf(.Items.Item(iFile), i) <> "" then        Debug.Print i, .getDetailsOf(iFile, i), .getDetailsOf(.Items.Item(iFile), i) 'Name + Inhalt
    Next i
End With
End Sub
 
Upvote 0
I can't find any modify creation date using namespace.items, I googled but nothing comes up, it does list Creation Time but no .modify name
 
Upvote 0

Forum statistics

Threads
1,215,494
Messages
6,125,137
Members
449,207
Latest member
VictorSiwiide

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top