Re: Modify existing Calendar event
Re: Modify existing Calendar event
- Subject: Re: Modify existing Calendar event
- From: Paul Berkowitz <email@hidden>
- Date: Fri, 19 Sep 2014 19:51:42 -0700
- Thread-topic: Modify existing Calendar event
Title: Re: Modify existing Calendar event
You can change the start and end times, and any other property listed in the dictionary that is not marked r/o, withoput having to delete and recreate the event. Here's how you would change the start time to 11 am and keep the length of the event the same:
tell application "Calendar"
set theEvent to event id "1DA59781-2C6A-49E7-8296-9EB95443FC45" of calendar "Work" -- use the id you need
tell theEvent
set theStartDate to start date
set theLength to end date - theStartDate
set time of theStartDate to (11 * hours)
set its start date to theStartDate
set its end date to (theStartDate + theLength)
end tell
end tell
--
Paul Berkowitz
> From: Bill Vlahos <email@hidden>
> Date: Fri, 19 Sep 2014 17:58:24 -0700
> To: Jay louvion <email@hidden>
> Cc: AppleScript-Users <email@hidden>
> Subject: Re: Modify existing Calendar event
>
> Jay,
Thanks. That would work if needed but it would lose the list of invitees
> already in the invitation. Those would have to be redone.
Is there no way to
> modify an existing meeting?
Bill
On Sep 19, 2014, at 12:04 AM, Jay louvion
> <email@hidden> wrote:
>
> I have had a working script for years
> that deletes and rewrites an event with the modifications.
>
> J
>
> Sent
> from my iRoningboard
>
>> On 19 sept. 2014, at 08:11, Bill Vlahos
> <email@hidden> wrote:
>>
>> I can create a new calendar item via
> AppleScript.
>>
>> If I know the UID of the event, how can I change portions
> of it?
>>
>> Example: I scheduled a meeting at 10am for one hour using an
> application I am writing. I now want to use my application to change something
> about the meeting. For example; I want to change the start time to 11am.
>>
>
>> How would I do that via AppleScript?
>>
>> Thank you,
>> Bill Vlahos
>>
> _______________________________________________
>> Do not post admin requests
> to the list. They will be ignored.
>> AppleScript-Users mailing list
> (email@hidden)
>> Help/Unsubscribe/Update your
> Subscription:
>>
> de.com
>> 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:
> email@hidden
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:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden