P
peterthebag
HI,
I posted a coule of weeks ago, but that was during the developer
conference, and I only got one reply, hence the repost.
What I am wanting to do is to use a script to "automate" creation of
entourage events. It should display dialogue boxes which I input
data 
into, which it then uses to create the events. I am trying to
get it 
to set all the major properties: name, start and end date and
time, 
category, and repetition.
I have tried several ways of doing this, but all I can do is get it
to 
create an event with the name and category I give it. Everything
else 
is ignored
the code I am currently using is:
tell application "Microsoft Entourage"
-- get the information from the user, and store it in variables
display dialog "Subject: " default answer ""
set theName to the text returned of the result
display dialog "Enter Event Category: " default answer ""
set theCategory to the text returned of the result
display dialog "Enter Start of the event: " default answer ""
set myStart to the text returned of the result
display dialog "duration of event in minutes" default answer ""
set mytime to the text returned of the result
-- create a new event with the information from the usre input
set newEvent to make new event with properties ¬
{subject:theName, category:{category theCategory}}
set theStart to date myStart
set theend to date ((myStart) + 1 * hours)
-- set times of event
set start time of newEvent to theStart
set end time of newEvent to theend
end tell
Entourage simply won't takes the dates. It says: Can't get date
"29/06/2007, 13:00"
I've tried some of this in the script editor and it seems that the
dates are in the right date class format, so I just dont understand
where i'm going wrong. Does anyone know how I can make this work?
Also, can anyone advise as to how i can do recurrance?
Thanks, Peter
I posted a coule of weeks ago, but that was during the developer
conference, and I only got one reply, hence the repost.
What I am wanting to do is to use a script to "automate" creation of
entourage events. It should display dialogue boxes which I input
data 
into, which it then uses to create the events. I am trying to
get it 
to set all the major properties: name, start and end date and
time, 
category, and repetition.
I have tried several ways of doing this, but all I can do is get it
to 
create an event with the name and category I give it. Everything
else 
is ignored
the code I am currently using is:
tell application "Microsoft Entourage"
-- get the information from the user, and store it in variables
display dialog "Subject: " default answer ""
set theName to the text returned of the result
display dialog "Enter Event Category: " default answer ""
set theCategory to the text returned of the result
display dialog "Enter Start of the event: " default answer ""
set myStart to the text returned of the result
display dialog "duration of event in minutes" default answer ""
set mytime to the text returned of the result
-- create a new event with the information from the usre input
set newEvent to make new event with properties ¬
{subject:theName, category:{category theCategory}}
set theStart to date myStart
set theend to date ((myStart) + 1 * hours)
-- set times of event
set start time of newEvent to theStart
set end time of newEvent to theend
end tell
Entourage simply won't takes the dates. It says: Can't get date
"29/06/2007, 13:00"
I've tried some of this in the script editor and it seems that the
dates are in the right date class format, so I just dont understand
where i'm going wrong. Does anyone know how I can make this work?
Also, can anyone advise as to how i can do recurrance?
Thanks, Peter