Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Enthusiast Zone > Classic Macs and Mac OS > Change the creation date?

Change the creation date?
Thread Tools
Dedicated MacNNer
Join Date: Apr 2002
Location: Chicago
Status: Offline
Reply With Quote
May 30, 2002, 07:32 PM
 
I know its possible to change the modification date of a file with AppleScript. The Finder dictionary lists the creation date as a r/o property. Is there any way to change the creation date of a file?
     
Forum Regular
Join Date: Feb 2001
Status: Offline
Reply With Quote
May 31, 2002, 12:42 AM
 
Use this:

tell app "Disk Copy"
set creation date of disk image "Path" to date "date"
end tell

This requires Classic's Disk Copy.

(159)
     
Dedicated MacNNer
Join Date: Apr 2002
Location: Chicago
Status: Offline
Reply With Quote
May 31, 2002, 09:18 AM
 
I couldn't get your script to work. How do I script this example:

Change the creation date of the SimpleText file "test" (which is on my desktop) to "Thursday, April 1, 1976 12:00:00 AM".
     
Forum Regular
Join Date: Feb 2001
Status: Offline
Reply With Quote
May 31, 2002, 01:14 PM
 
Use this:

tell app "Disk Copy"
set creation date of disk image "Macintosh HDesktop Folder:test" to date "Thursday, April 1, 1976 0:00:00"
end tell

(160)
     
Forum Regular
Join Date: May 2001
Location: Hong Kong
Status: Offline
Reply With Quote
May 31, 2002, 04:29 PM
 
Why not use ResEdit?

<small>[ 05-31-2002, 03:31 PM: Message edited by: MacMonster ]</small>
     
Dedicated MacNNer
Join Date: Apr 2002
Location: Chicago
Status: Offline
Reply With Quote
Jun 1, 2002, 09:29 AM
 
</font><blockquote><font size="1" face="Geneva, Verdana, Arial, sans-serif">quote:</font><hr /><font size="1" face="Geneva, Verdana, Arial, sans-serif">Originally posted by AppleScript:
<strong>Use this:

tell app "Disk Copy"
set creation date of disk image "Macintosh HDesktop Folder:test" to date "Thursday, April 1, 1976 0:00:00"
end tell

(160)</strong></font><hr /></blockquote><font size="1" face="Geneva, Verdana, Arial, sans-serif">Thanks AppleScript, it worked fine.
I think I mistyped the file path when I originally tried your script.

Thanks again
     
Clinically Insane
Join Date: Apr 2000
Status: Offline
Reply With Quote
Jun 1, 2002, 10:04 AM
 
</font><blockquote><font size="1" face="Geneva, Verdana, Arial, sans-serif">quote:</font><hr /><font size="1" face="Geneva, Verdana, Arial, sans-serif">Originally posted by MacMonster:
<strong>Why not use ResEdit?</strong></font><hr /></blockquote><font size="1" face="Geneva, Verdana, Arial, sans-serif">ResEdit isn't scriptable... if it was... wow, that'd be some power under the hood.

The initial requirement was for an AppleScript to do this.
     
Dedicated MacNNer
Join Date: Apr 2002
Location: Chicago
Status: Offline
Reply With Quote
Jun 1, 2002, 11:08 AM
 
</font><blockquote><font size="1" face="Geneva, Verdana, Arial, sans-serif">quote:</font><hr /><font size="1" face="Geneva, Verdana, Arial, sans-serif"><strong>Originally posted by Cipher13:
ResEdit isn't scriptable... if it was... wow, that'd be some power under the hood.</strong></font><hr /></blockquote><font size="1" face="Geneva, Verdana, Arial, sans-serif">Sure would!!!

</font><blockquote><font size="1" face="Geneva, Verdana, Arial, sans-serif">quote:</font><hr /><font size="1" face="Geneva, Verdana, Arial, sans-serif"><strong>The initial requirement was for an AppleScript to do this.</strong></font><hr /></blockquote><font size="1" face="Geneva, Verdana, Arial, sans-serif">Actually, I didn't care what app accomplished this - But - Since Applescript showed me how to do this using Applescript and Disk Copy, I can write an Applescript droplet instead of having to:

1. Open the file with ResEdit
2. Hack the creation date
3. Save the file

If I ever have to do this again, it will be a one step process.

Drag and Drop - Thats the way to do it!
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -4. The time now is 12:59 PM.
All contents of these forums © 1995-2015 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.8 © 2000-2015, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2