A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Add-ins for Outlook
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Outlook 2007 Ribbon access from ActiveX control



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old May 24th 07, 09:41 PM posted to microsoft.public.outlook.program_addins
GR
external usenet poster
 
Posts: 10
Default Outlook 2007 Ribbon access from ActiveX control

Hi All,

I have an ActiveX Control (.ocx) written in VB6 that I put on the
second page tab in an Outlook Appointment custom form. This works fine
for Outlook 2000-2003. I am now trying to port this into a separate
project to work with Outlook 2007.

So far, everything seems to come up and display fine. Now what I am
trying to do is to capture the buttons (Send, Send Update, etc...)
from the Ribbon like I do for the CommandBars in the previous Outlook
versions.

I have added the "Implements Office.IRibbonExtensibility" line into
the project and it automatically created the
"IRibbonExtensibility_GetCustomUI( )" function in the project for me.
In this function is where I added the XML code to register an onAction
callback for some of the buttons (I have used this exact same xml code
in another .dll and it worked fine).

The problem is that the "IRibbonExtensibility_GetCustomUI" function
does not seem to be getting called at all when the control is
activated. I put a messagebox at the top of that function and it never
gets to it, thereby never getting the XML code for the button
callback. What I don't understand is who calls that function
specifically. In the "UserControl_Show( )" sub is where I used to set
the Commandbars codes for the buttons I wanted to intercept. However,
I don't think I can just call the "IRibbonExtensibility_GetCustomUI"
function myself, right? It needs the RibbonID passed into it and I'm
assuming tied back to the Ribbon somehow.

I'm missing how the Ribbon gets set to the procedures in the ActiveX
control. In my DLL project, the "IRibbonExtensibility_GetCustomUI"
function gets called automatically when the DLL is loaded.

Any help? Thanks!

Ads
  #2  
Old May 25th 07, 12:30 AM posted to microsoft.public.outlook.program_addins
Patrick Schmid [MVP]
external usenet poster
 
Posts: 173
Default Outlook 2007 Ribbon access from ActiveX control

You can't do this. RibbonX can only be supplied via Outlook COM Add-ins.
ActiveX controls cannot supply RibbonX.

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Outlook 2007 Performance Update: http://pschmid.net/blog/2007/04/13/105
Office 2007 RTM Issues: http://pschmid.net/blog/2006/11/13/80
***
Customize Office 2007: http://pschmid.net/office2007/customize
RibbonCustomizer Add-In: http://ribboncustomizer.com
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed




"GR" wrote in message
oups.com:

Hi All,

I have an ActiveX Control (.ocx) written in VB6 that I put on the
second page tab in an Outlook Appointment custom form. This works fine
for Outlook 2000-2003. I am now trying to port this into a separate
project to work with Outlook 2007.

So far, everything seems to come up and display fine. Now what I am
trying to do is to capture the buttons (Send, Send Update, etc...)
from the Ribbon like I do for the CommandBars in the previous Outlook
versions.

I have added the "Implements Office.IRibbonExtensibility" line into
the project and it automatically created the
"IRibbonExtensibility_GetCustomUI( )" function in the project for me.
In this function is where I added the XML code to register an onAction
callback for some of the buttons (I have used this exact same xml code
in another .dll and it worked fine).

The problem is that the "IRibbonExtensibility_GetCustomUI" function
does not seem to be getting called at all when the control is
activated. I put a messagebox at the top of that function and it never
gets to it, thereby never getting the XML code for the button
callback. What I don't understand is who calls that function
specifically. In the "UserControl_Show( )" sub is where I used to set
the Commandbars codes for the buttons I wanted to intercept. However,
I don't think I can just call the "IRibbonExtensibility_GetCustomUI"
function myself, right? It needs the RibbonID passed into it and I'm
assuming tied back to the Ribbon somehow.

I'm missing how the Ribbon gets set to the procedures in the ActiveX
control. In my DLL project, the "IRibbonExtensibility_GetCustomUI"
function gets called automatically when the DLL is loaded.

Any help? Thanks!


  #3  
Old May 27th 07, 11:07 PM posted to microsoft.public.outlook.program_addins
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Outlook 2007 Ribbon access from ActiveX control

To add to what Patrick said, the code that Implements the ribbon must also
be the code that Implements IDTExtensibility2.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"Patrick Schmid [MVP]" wrote in message
...
You can't do this. RibbonX can only be supplied via Outlook COM Add-ins.
ActiveX controls cannot supply RibbonX.

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Outlook 2007 Performance Update: http://pschmid.net/blog/2007/04/13/105
Office 2007 RTM Issues: http://pschmid.net/blog/2006/11/13/80
***
Customize Office 2007: http://pschmid.net/office2007/customize
RibbonCustomizer Add-In: http://ribboncustomizer.com
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed


  #4  
Old May 29th 07, 04:44 PM posted to microsoft.public.outlook.program_addins
GR
external usenet poster
 
Posts: 10
Default Outlook 2007 Ribbon access from ActiveX control

On May 27, 6:07 pm, "Ken Slovak - [MVP - Outlook]"
wrote:
To add to what Patrick said, the code that Implements the ribbon must also
be the code that Implements IDTExtensibility2.

--
Ken Slovak
[MVP - Outlook]http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Optionshttp://www.slovaktech.com/products.htm

"Patrick Schmid [MVP]" wrote in l...



You can't do this. RibbonX can only be supplied via Outlook COM Add-ins.
ActiveXcontrols cannot supply RibbonX.


Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Outlook 2007 Performance Update:http://pschmid.net/blog/2007/04/13/105
Office 2007 RTM Issues:http://pschmid.net/blog/2006/11/13/80
***
Customize Office 2007:http://pschmid.net/office2007/customize
RibbonCustomizer Add-In:http://ribboncustomizer.com
OneNote 2007:http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog:http://pschmid.net/blog/feed- Hide quoted text -


- Show quoted text -


Hi Patrick & Ken,

Thanks for the replies!

Just to be sure I'm clear on this and that I explained myself
properly:

I have a COM AddIn (.dll) for Outlook 20007 that puts a button on the
command bar. When the user presses this button it opens up a custom
form (based on the Outlook meeting form). There the user fills in some
info and tabs to the second page where my ActiveX (.ocx) control
resides on the form. The control gets activated and performs some
functions. It is at this point that I want the ActiveX control to be
able to intercept any buttons (eg: Send, etc...) that the user pressed
on the Ribbon, just like I used to do with CommandBars for Outlook
2003.

Are you saying that this is no longer possible like I used to be able
to do with the CommnadBars? Any alternatives pop to mind?

Thanks!

  #5  
Old May 29th 07, 05:24 PM posted to microsoft.public.outlook.program_addins
Patrick Schmid [MVP]
external usenet poster
 
Posts: 173
Default Outlook 2007 Ribbon access from ActiveX control

Why don't you have the COM add-in handle all of the UI interaction?

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Outlook 2007 Performance Update: http://pschmid.net/blog/2007/04/13/105
Office 2007 RTM Issues: http://pschmid.net/blog/2006/11/13/80
***
Customize Office 2007: http://pschmid.net/office2007/customize
RibbonCustomizer Add-In: http://ribboncustomizer.com
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed




"GR" wrote in message
ups.com:

On May 27, 6:07 pm, "Ken Slovak - [MVP - Outlook]"
wrote:
To add to what Patrick said, the code that Implements the ribbon must also
be the code that Implements IDTExtensibility2.

--
Ken Slovak
[MVP - Outlook]http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Optionshttp://www.slovaktech.com/products.htm

"Patrick Schmid [MVP]" wrote in l...



You can't do this. RibbonX can only be supplied via Outlook COM Add-ins.
ActiveXcontrols cannot supply RibbonX.


Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Outlook 2007 Performance Update:http://pschmid.net/blog/2007/04/13/105
Office 2007 RTM Issues:http://pschmid.net/blog/2006/11/13/80
***
Customize Office 2007:http://pschmid.net/office2007/customize
RibbonCustomizer Add-In:http://ribboncustomizer.com
OneNote 2007:http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog:http://pschmid.net/blog/feed- Hide quoted text -


- Show quoted text -


Hi Patrick & Ken,

Thanks for the replies!

Just to be sure I'm clear on this and that I explained myself
properly:

I have a COM AddIn (.dll) for Outlook 20007 that puts a button on the
command bar. When the user presses this button it opens up a custom
form (based on the Outlook meeting form). There the user fills in some
info and tabs to the second page where my ActiveX (.ocx) control
resides on the form. The control gets activated and performs some
functions. It is at this point that I want the ActiveX control to be
able to intercept any buttons (eg: Send, etc...) that the user pressed
on the Ribbon, just like I used to do with CommandBars for Outlook
2003.

Are you saying that this is no longer possible like I used to be able
to do with the CommnadBars? Any alternatives pop to mind?

Thanks!


 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Outlook 2007 No Ribbon Henry Hicks Outlook - General Queries 5 May 31st 07 02:18 PM
Modifying of the Ribbon in Outlook 2007 Steffen Grellmann Add-ins for Outlook 1 March 20th 07 01:00 PM
Outlook 2007 / Addin with Ribbon Paul Liebrand Add-ins for Outlook 3 February 5th 07 09:12 PM
Ribbon and Quick Access Toolbar not appearing in Outlook 2007 David Outlook - Installation 1 January 19th 07 08:47 PM
Outlook 2007 - why no ribbon? Daern's Instant Fortress Outlook - General Queries 1 May 24th 06 05:56 PM


All times are GMT +1. The time now is 07:11 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.