Group:  Microsoft Outlook » microsoft.public.outlook.program_addins
Thread: Create Add-in for multiple versions of Outlook

Geek News

Create Add-in for multiple versions of Outlook
ivan.pololi[ at ]gmail.com 12/30/2008 11:21:50 AM
Hello,

I'm creating an add-in for Outlook and I need it to work both with
Outlook XP (2002) and Outlook 2007.

I created it using Microsoft Outlook 10.0 Object Library (Outlook
2002) and it works fine on Outlook XP.

When I execute it on Outlook 2007 it works ok but the events don't
fire. For example I have this piece of code but the Startup event
doesn't fire in Outlook 2007:

Private Sub outAppStartup() Handles outApp.Startup
Log("ActiveExplorerCBars.0")
ActiveExplorerCBars = outApp.ActiveExplorer.CommandBars
Log("ActiveExplorerCBars.1")
End Sub

What can I check? Is there another method for creating add-in for
multiple Outlook versions?

Thank you very much and Happy New Year!

Ivan Pololi
Italy
Re: Create Add-in for multiple versions of Outlook
"Ken Slovak - [MVP - Outlook]" <kenslovak[ at ]mvps.org> 12/30/2008 1:59:10 PM
You say it works OK, do you get the OnConnection() event?

What is supposed to trigger the outApp.Startup() event? What other events
don't fire?

How is this addin constructed? What language?

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


<ivan.pololi[ at ]gmail.com> wrote in message
news:62c58800-8953-47d7-b5e8-561062d2b270[ at ]w1g2000prm.googlegroups.com...
[Quoted Text]
> Hello,
>
> I'm creating an add-in for Outlook and I need it to work both with
> Outlook XP (2002) and Outlook 2007.
>
> I created it using Microsoft Outlook 10.0 Object Library (Outlook
> 2002) and it works fine on Outlook XP.
>
> When I execute it on Outlook 2007 it works ok but the events don't
> fire. For example I have this piece of code but the Startup event
> doesn't fire in Outlook 2007:
>
> Private Sub outAppStartup() Handles outApp.Startup
> Log("ActiveExplorerCBars.0")
> ActiveExplorerCBars = outApp.ActiveExplorer.CommandBars
> Log("ActiveExplorerCBars.1")
> End Sub
>
> What can I check? Is there another method for creating add-in for
> multiple Outlook versions?
>
> Thank you very much and Happy New Year!
>
> Ivan Pololi
> Italy

Re: Create Add-in for multiple versions of Outlook
ivan.pololi[ at ]gmail.com 12/30/2008 2:23:23 PM
It is build with VB.NET, using the Shared-Add-in project.

The OnConnection Event works fine.

outApp.StartUp should fire on Outlook Application.Startup event.

Also OnUpdate on CommandBars doesn't start.

Thanx,
Ivan

On 30 Dic, 14:59, "Ken Slovak - [MVP - Outlook]" <kenslo...[ at ]mvps.org>
wrote:
[Quoted Text]
> You say it works OK, do you get the OnConnection() event?
>
> What is supposed to trigger the outApp.Startup() event? What other events
> don't fire?
>
> How is this addin constructed? What language?
>
> --
> Ken Slovak
> [MVP - Outlook]http://www.slovaktech.com
> Author: Professional Programming Outlook 2007.
> Reminder Manager, Extended Reminders, Attachment Options.http://www.slovaktech.com/products.htm
>
> <ivan.pol...[ at ]gmail.com> wrote in message
>
> news:62c58800-8953-47d7-b5e8-561062d2b270[ at ]w1g2000prm.googlegroups.com...
>
>
>
> > Hello,
>
> > I'm creating an add-in for Outlook and I need it to work both with
> > Outlook XP (2002) and Outlook 2007.
>
> > I created it using Microsoft Outlook 10.0 Object Library (Outlook
> > 2002) and it works fine on Outlook XP.
>
> > When I execute it on Outlook 2007 it works ok but the events don't
> > fire. For example I have this piece of code but the Startup event
> > doesn't fire in Outlook 2007:
>
> > Private Sub outAppStartup() Handles outApp.Startup
> >     Log("ActiveExplorerCBars.0")
> >     ActiveExplorerCBars = outApp.ActiveExplorer.CommandBars
> >     Log("ActiveExplorerCBars.1")
> > End Sub
>
> > What can I check? Is there another method for creating add-in for
> > multiple Outlook versions?
>
> > Thank you very much and Happy New Year!
>
> > Ivan Pololi
> > Italy- Nascondi testo citato
>
> - Mostra testo citato -

Re: Create Add-in for multiple versions of Outlook
"Ken Slovak - [MVP - Outlook]" <kenslovak[ at ]mvps.org> 12/30/2008 2:58:29 PM
If you get OnConnection you shouldn't bother with Startup, which fires
before OnConnection anyway.

You also may not get a valid ActiveExplorer at that point, certainly not
with Startup. Use the OnStartupComplete event for trying to get
ActiveExplorer. If ActiveExplorer isn't valid then handling OnUpdate won't
work.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


<ivan.pololi[ at ]gmail.com> wrote in message
news:0dfb49e0-e891-4668-a8fc-20d67a0ba566[ at ]o4g2000pra.googlegroups.com...
It is build with VB.NET, using the Shared-Add-in project.

The OnConnection Event works fine.

outApp.StartUp should fire on Outlook Application.Startup event.

Also OnUpdate on CommandBars doesn't start.

Thanx,
Ivan

Home | Search | Terms | Imprint Contact
Newsgroups Reader - provided by WiredBox.Net