Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

outlook agenda

Status
Not open for further replies.

fluppe689

Programmer
Jul 11, 2008
75
BE
Dear Experts,

Is it possible to read en use the information from different agenda's from exchange server.
And if this is possible how to do ?

wfg,

Filip Merlier
 
Hi Filip,

You mentioned Outlook in your thread title, so I assume you want to do this via the Outlook client. If so, you could do something like this:

Code:
oOut = CREATEOBJECT("outlook.application")
oNS = oOut.GetNamespace("MAPI")
oAgenda = oNS.GetDefaultFolder(9)
oItem = oAgenda.Items(1)   && Get first agenda item
? oItem.Subject
? oItem.Start
? oItem.End
? oItem.Importance
? oItem.Body
? oItem.Duration
? oItem.Location

You could also loop through oAgenda.Items to get each item in turn.

Does that answer your question?

Mike

__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips, training, consultancy
 
Thanks Mike,

question 1 : how can I import agenda of different users ?
question 2 : how can i know how much items ther are ?

Wfg,

Filip Merlier
 
question 1 : how can I import agenda of different users ?

Not sure off the top of my head. I'll check it when I've got more time (unless someone else answers it first).

question 2 : how can i know how much items ther are ?

Do this:

Code:
? oAgenda.Items.Count

You can also loop through the collection like this:

Code:
FOR EACH loItem IN oAgenda.Items
  * Do something here with loItem
ENDFOR

Mike



__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips, training, consultancy
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top