CopyTo() does not do its job in Outlook XP

S

smp2200a

I wrote a small VBS to copy a user's Calendar folder to Admin's local .pst file. It works fine on a machine with Outlook 2000 but not on Outlook XP. On the Outlook XP machine, I also get several pop-up windows asking if I want to allow this program to access the information stored in Outlook. Lowering the security level to low didn't help much - the windows still pop up. Please let me share your tips on how to make CopyTo work for Outlook XP and to avoid pop-up windows. Thanks

Here is the script. I run this when Outlook is up and running
=============================
Set ol = CreateObject ("Outlook.Application"
Set ns = ol.GetNameSpace ("MAPI"
Set myRecipient = ns.CreateRecipient("SourceUser"
myRecipient.Resolv
If myRecipient.Resolved The
Set contacts = ns.GetSharedDefaultFolder(myRecipient, 9
End I
set localFolder = ns.Folders("Personal Folders"
set newfolder = contacts.CopyTo(localFolder
====================================
 

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