|
|
Change the creation date?
|
|
|
|
Dedicated MacNNer
Join Date: Apr 2002
Location: Chicago
Status:
Offline
|
|
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
|
|
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
|
|
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
|
|
Use this:
tell app "Disk Copy"
set creation date of disk image "Macintosh HD esktop 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
|
|
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
|
|
</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 HD esktop 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
|
|
|
|
|
|
|
|
|
Registered User
Join Date: Apr 2000
Status:
Offline
|
|
</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
|
|
</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!
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Forum Rules
|
|
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is Off
|
|
|
|
|
|
|
|
|
|
|
|