Assigning an Outlook template to a toolbar

G

Guest

What VBA script do I use in my macros to assign a .oft file to a toolbar
button?

Thanks.
 
S

Sue Mosher [MVP-Outlook]

You can use Application.CreateItemFromTemplate.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
G

Guest

Thanks for your speedy reply Sue. I am a relative novice at VBA scripting.
Are you able to help me with the whole script?
 
S

Sue Mosher [MVP-Outlook]

Then it's time you learned about the Object Browser: Press ALt+F11 to open the VBA environment in Outlook, then press F2. Switch from <All Libraries> to Outlook to browse all Outlook objects and their properties, methods, and events. Select any object or member, then press F1 to see its Help topic, usually including sample code.

Note that VBA, like VBScript, has an intrinsic Application object, so you don't need this statement:

Set myOlApp = CreateObject("Outlook.Application")

You can use this instead:

Set myOlApp = Application

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 

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