O2007, ThisAddIn_Startup and custom calendar creation

S

senglory

I'm trying to create custom calendar in Startup handler in my VSTO. It
creates successfully:

Code:
_ns = Me.Application.GetNamespace("MAPI")
Me._colCalendar =
_ns.GetDefaultFolder(Outlook.OlDefaultFolders.olFolderCalendar)
nf = Me._colCalendar.Folders.Add("MY CALENDAR NAME",
Outlook.OlDefaultFolders.olFolderCalendar)


but I don't see it in calendars list after Outlook showed up on my monitor.
What's wrong to my code?
 
B

Brian Tillman [MVP-Outlook]

I'm trying to create custom calendar in Startup handler in my VSTO. It
creates successfully:

Code:
_ns = Me.Application.GetNamespace("MAPI")
Me._colCalendar =
_ns.GetDefaultFolder(Outlook.OlDefaultFolders.olFolderCalendar)
nf = Me._colCalendar.Folders.Add("MY CALENDAR NAME",
Outlook.OlDefaultFolders.olFolderCalendar)


but I don't see it in calendars list after Outlook showed up on my monitor.
What's wrong to my code?

Ask in the programming group microsoft.public.outlook.program_addins
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top