Title: Re: Completed dates for tasks...
On or near 7/2/04 7:14 AM, Paul Berkowitz at [EMAIL PROTECTED] observed:

> On 7/2/04 2:52 AM, "Kirk McElhearn" <[EMAIL PROTECTED]> wrote:
>
>> However, if I read a completed task, or especially if I add comments to it,
>> then it won't work... So in that case, I'd have to enter a date in the
>> comments field.
>
> If you
> label any such date with a "Completed: " label, you'll only need to search
> for a line beginning that way.

I have a script that inserts date, time, or both; easily modified to include the word "Completed: " if you wish:

set X to (current date) as string
set oldDelims to AppleScript's text item delimiters
set AppleScript's text item delimiters to {" "}
set temp to text items of X
set d to items 1 thru 4 of temp as text
set t to items -2 thru -1 of temp as text
set t to text 1 thru -7 of t & text -3 thru -1 of t
set AppleScript's text item delimiters to oldDelims
set doWhich to button returned of (display dialog ¬
    "Insert time, date or both?" buttons {"Time", "Date", "Both"} default button "Time")
if doWhich = "Time" then
    set s to t
else if doWhich = "Date" then
    set s to d
else
    set s to d & " at " & t
end if
tell application "Microsoft Entourage"
    activate
    try
        set the selection to s
    on error theErr
        display dialog theErr
    end try
end tell

Friday, July 2, 2004; that's how the date gets inserted. I assign it a shortcut of Shift-Option-T (could be D), and obviously, you could dispense with the dialog if all you ever want is "Completed: Friday, July 2, 2004".

Reply via email to