1
$\begingroup$

Is it possible to change file attributes external to Mathematica, such as DOC, JPG, ...?

I'd like to change the Creation Date of a batch file from a folder with DOC files, for example.

EDIT:

I did a test based on some comment, but the modification only appears in the file properties and disappears in Windows Explorer.

SetFileDate["C:\\Users\\Leandro\\Desktop\\Teste\\2017-06-03 \
22.05.14.jpg", {1978, 1, 10, 00, 10, 20}, "Creation"]

enter image description here

$\endgroup$

migrated from mathematica.meta.stackexchange.com Jun 15 '17 at 17:25

This question came from our discussion, support, and feature requests site for users of Wolfram Mathematica.

  • $\begingroup$ This is more of a Super User question. $\endgroup$ – J. M. will be back soon May 25 '17 at 17:05
  • 2
    $\begingroup$ It might be better if you just ask the question without mention of Mathematica there, since this really has nothing to do with Mathematica. $\endgroup$ – J. M. will be back soon May 25 '17 at 17:14
  • 1
    $\begingroup$ I don't believe Mathematica has a function to do this specifically so you would need to call an external command line utility like attrib under Windows. $\endgroup$ – Mr.Wizard May 25 '17 at 19:05
  • 2
    $\begingroup$ I'm not sure I understand the question, but if you want to use Mathematica to change the creation date of a file: SetFileDate["zot.bat", {2017, 5, 20, 1, 23, 45}, "Creation"]. $\endgroup$ – WReach May 25 '17 at 23:58
  • 1
    $\begingroup$ Confirmed, the issue lies with the actual date: setting the date via SetFileDate older than 1980 causes windows to show a blank in the folder list creation date field. $\endgroup$ – george2079 Jun 15 '17 at 19:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.