Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: last opened



Is the LastUsedDate in some way distinct from the UNIX atime? (which
you can get with ls -u)...

On 3/22/07, Takaaki Naganoya <email@hidden> wrote:
How about "mdls" command on BSD layer?
"mdls" tells you the last used date.

<AppleScript>
set aFile to choose file
set aPOSIXpath to quoted form of POSIX path of aFile
set shellText to "mdls -name " & (ASCII character 34) &
"kMDItemLastUsedDate" & (ASCII character 34) & " " & aPOSIXpath
do shell script shellText
</AppleScript>

--> "/Users/maro/Documents/1307643.rtf -------------
kMDItemLastUsedDate = 2007-03-22 16:24:00 +0900"

And just cook the date text.

--
Takaaki Naganoya
Piyomaru Software
http://piyo.piyocast.com
email@hidden

On 2007/03/19, at 20:20, Wayne Melrose wrote:

> In the Finder "get properties", it shows the "last modification date".
>
> Is there a way to find the "last opened" date? (The same way that
> you can searching in Finder.)
>
> thanks in advance.
>
> Wayne
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> AppleScript-Users mailing list      (applescript-
> email@hidden)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/applescript-users/maro%40b-
> mark.nu
> Archives: http://lists.apple.com/archives/applescript-users
>
> This email sent to email@hidden
>

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/applescript-users/email@hidden
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden



--
Mark J. Reed <email@hidden>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/applescript-users/email@hidden
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden
References: 
 >last opened (From: Wayne Melrose <email@hidden>)
 >Re: last opened (From: Takaaki Naganoya <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.