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 Click a Button on the Ribbon through Code



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old December 14th 06, 02:48 AM posted to microsoft.public.outlook.program_addins
[email protected]
external usenet poster
 
Posts: 23
Default Outlook 2007 Click a Button on the Ribbon through Code

Hello all,

I need to insert a signature into an E-mail through code in Outlook
2007.

Does anyone know how I may be able to execute one of the Signatures
from the Signature menu on the Ribbon?

I know about the ExecuteMso method, but how do I get the idMso for the
signatures that appear on the menu when a new signature is inserted on
the Signature menu?

I am inserting a custom signature into the menu and and I need to
insert the signature into any new inspector when it opens up.

In Outlook 2003, i was able to Find the commandbars object for the
signature menu (using FindControl(ID)) and then loop through the
commandbars collection to check the captions of the buttons and execute
the button with my custom signature.

How would I be able to achieve this in Outlook 2007?

Thank you for any help in advance.

Regards,
Neil Goundar.

  #2  
Old December 14th 06, 03:33 AM posted to microsoft.public.outlook.program_addins
Patrick Schmid [MVP]
external usenet poster
 
Posts: 173
Default Outlook 2007 Click a Button on the Ribbon through Code

I think you are out of luck. Your better bet is to look into accessing
the signatures and their insertion from the Outlook object model. I
don't do anything with Outlook that goes beyond the ribbon, so I'll
leave the question whether this is possible up to another replier.

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Office 2007 RTM Issues: http://pschmid.net/blog/2006/11/13/80
Office 2007 Beta 2 Technical Refresh (B2TR):
http://pschmid.net/blog/2006/09/18/43
***
Customize Office 2007: http://pschmid.net/office2007/customize
RibbonCustomizer Add-In: http://pschmid.net/office2007/ribboncustomizer
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed

" wrote in message
ups.com:

Hello all,

I need to insert a signature into an E-mail through code in Outlook
2007.

Does anyone know how I may be able to execute one of the Signatures
from the Signature menu on the Ribbon?

I know about the ExecuteMso method, but how do I get the idMso for the
signatures that appear on the menu when a new signature is inserted on
the Signature menu?

I am inserting a custom signature into the menu and and I need to
insert the signature into any new inspector when it opens up.

In Outlook 2003, i was able to Find the commandbars object for the
signature menu (using FindControl(ID)) and then loop through the
commandbars collection to check the captions of the buttons and execute
the button with my custom signature.

How would I be able to achieve this in Outlook 2007?

Thank you for any help in advance.

Regards,
Neil Goundar.


  #3  
Old December 14th 06, 04:58 AM posted to microsoft.public.outlook.program_addins
[email protected]
external usenet poster
 
Posts: 23
Default Outlook 2007 Click a Button on the Ribbon through Code

Hi Patrick,

Thank you for the reply. I have managed to solve this problem.

The CommandBars.FindControl that i was using in Outlook 2003 wasnt
working, but i observed that the commanbars collection is still
available in Outlook 2007.

From there it was just a matter of looping through the controls and

finding the one that I was looking for.

Could you confirm that I will not be able to click the Item on the
signature menu using ExecuteMso(idMso)?

Thank you for the help. I really appreciate it.

Regards,
Neil Goundar

Patrick Schmid [MVP] wrote:
I think you are out of luck. Your better bet is to look into accessing
the signatures and their insertion from the Outlook object model. I
don't do anything with Outlook that goes beyond the ribbon, so I'll
leave the question whether this is possible up to another replier.

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Office 2007 RTM Issues: http://pschmid.net/blog/2006/11/13/80
Office 2007 Beta 2 Technical Refresh (B2TR):
http://pschmid.net/blog/2006/09/18/43
***
Customize Office 2007: http://pschmid.net/office2007/customize
RibbonCustomizer Add-In: http://pschmid.net/office2007/ribboncustomizer
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed

" wrote in message
ups.com:

Hello all,

I need to insert a signature into an E-mail through code in Outlook
2007.

Does anyone know how I may be able to execute one of the Signatures
from the Signature menu on the Ribbon?

I know about the ExecuteMso method, but how do I get the idMso for the
signatures that appear on the menu when a new signature is inserted on
the Signature menu?

I am inserting a custom signature into the menu and and I need to
insert the signature into any new inspector when it opens up.

In Outlook 2003, i was able to Find the commandbars object for the
signature menu (using FindControl(ID)) and then loop through the
commandbars collection to check the captions of the buttons and execute
the button with my custom signature.

How would I be able to achieve this in Outlook 2007?

Thank you for any help in advance.

Regards,
Neil Goundar.


  #4  
Old December 14th 06, 05:06 AM posted to microsoft.public.outlook.program_addins
Patrick Schmid [MVP]
external usenet poster
 
Posts: 173
Default Outlook 2007 Click a Button on the Ribbon through Code

Could you confirm that I will not be able to click the Item on the
signature menu using ExecuteMso(idMso)?

There is no way to get the idMso...so, yes

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Office 2007 RTM Issues: http://pschmid.net/blog/2006/11/13/80
Office 2007 Beta 2 Technical Refresh (B2TR):
http://pschmid.net/blog/2006/09/18/43
***
Customize Office 2007: http://pschmid.net/office2007/customize
RibbonCustomizer Add-In: http://pschmid.net/office2007/ribboncustomizer
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed


Thank you for the help. I really appreciate it.

Regards,
Neil Goundar

Patrick Schmid [MVP] wrote:
I think you are out of luck. Your better bet is to look into accessing
the signatures and their insertion from the Outlook object model. I
don't do anything with Outlook that goes beyond the ribbon, so I'll
leave the question whether this is possible up to another replier.

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Office 2007 RTM Issues: http://pschmid.net/blog/2006/11/13/80
Office 2007 Beta 2 Technical Refresh (B2TR):
http://pschmid.net/blog/2006/09/18/43
***
Customize Office 2007: http://pschmid.net/office2007/customize
RibbonCustomizer Add-In: http://pschmid.net/office2007/ribboncustomizer
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed

" wrote in message
ups.com:

Hello all,

I need to insert a signature into an E-mail through code in Outlook
2007.

Does anyone know how I may be able to execute one of the Signatures
from the Signature menu on the Ribbon?

I know about the ExecuteMso method, but how do I get the idMso for the
signatures that appear on the menu when a new signature is inserted on
the Signature menu?

I am inserting a custom signature into the menu and and I need to
insert the signature into any new inspector when it opens up.

In Outlook 2003, i was able to Find the commandbars object for the
signature menu (using FindControl(ID)) and then loop through the
commandbars collection to check the captions of the buttons and execute
the button with my custom signature.

How would I be able to achieve this in Outlook 2007?

Thank you for any help in advance.

Regards,
Neil Goundar.


  #5  
Old December 14th 06, 08:01 PM posted to microsoft.public.outlook.program_addins
[email protected]
external usenet poster
 
Posts: 23
Default Outlook 2007 Click a Button on the Ribbon through Code

Hello Patrick,

Thank you for the confirmation. That is what i thought.

On another note, since i am observing that commandbars is still
available for use, i am asking myself what is the guarantee that
microsoft does not remove the commandbars altogether in the future
since the Ribbon has come into the picture. I guess i'll make do with
the commanbars for now.

Regards,
Neil Goundar

Patrick Schmid [MVP] wrote:
Could you confirm that I will not be able to click the Item on the
signature menu using ExecuteMso(idMso)?

There is no way to get the idMso...so, yes

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Office 2007 RTM Issues: http://pschmid.net/blog/2006/11/13/80
Office 2007 Beta 2 Technical Refresh (B2TR):
http://pschmid.net/blog/2006/09/18/43
***
Customize Office 2007: http://pschmid.net/office2007/customize
RibbonCustomizer Add-In: http://pschmid.net/office2007/ribboncustomizer
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed


Thank you for the help. I really appreciate it.

Regards,
Neil Goundar

Patrick Schmid [MVP] wrote:
I think you are out of luck. Your better bet is to look into accessing
the signatures and their insertion from the Outlook object model. I
don't do anything with Outlook that goes beyond the ribbon, so I'll
leave the question whether this is possible up to another replier.

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Office 2007 RTM Issues: http://pschmid.net/blog/2006/11/13/80
Office 2007 Beta 2 Technical Refresh (B2TR):
http://pschmid.net/blog/2006/09/18/43
***
Customize Office 2007: http://pschmid.net/office2007/customize
RibbonCustomizer Add-In: http://pschmid.net/office2007/ribboncustomizer
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed

" wrote in message
ups.com:

Hello all,

I need to insert a signature into an E-mail through code in Outlook
2007.

Does anyone know how I may be able to execute one of the Signatures
from the Signature menu on the Ribbon?

I know about the ExecuteMso method, but how do I get the idMso for the
signatures that appear on the menu when a new signature is inserted on
the Signature menu?

I am inserting a custom signature into the menu and and I need to
insert the signature into any new inspector when it opens up.

In Outlook 2003, i was able to Find the commandbars object for the
signature menu (using FindControl(ID)) and then loop through the
commandbars collection to check the captions of the buttons and execute
the button with my custom signature.

How would I be able to achieve this in Outlook 2007?

Thank you for any help in advance.

Regards,
Neil Goundar.


  #6  
Old December 14th 06, 08:04 PM posted to microsoft.public.outlook.program_addins
Patrick Schmid [MVP]
external usenet poster
 
Posts: 173
Default Outlook 2007 Click a Button on the Ribbon through Code

Who knows what Microsoft will do?

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Office 2007 RTM Issues: http://pschmid.net/blog/2006/11/13/80
Office 2007 Beta 2 Technical Refresh (B2TR):
http://pschmid.net/blog/2006/09/18/43
***
Customize Office 2007: http://pschmid.net/office2007/customize
RibbonCustomizer Add-In: http://pschmid.net/office2007/ribboncustomizer
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed

" wrote in message
ups.com:

Hello Patrick,

Thank you for the confirmation. That is what i thought.

On another note, since i am observing that commandbars is still
available for use, i am asking myself what is the guarantee that
microsoft does not remove the commandbars altogether in the future
since the Ribbon has come into the picture. I guess i'll make do with
the commanbars for now.

Regards,
Neil Goundar

Patrick Schmid [MVP] wrote:
Could you confirm that I will not be able to click the Item on the
signature menu using ExecuteMso(idMso)?

There is no way to get the idMso...so, yes

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Office 2007 RTM Issues: http://pschmid.net/blog/2006/11/13/80
Office 2007 Beta 2 Technical Refresh (B2TR):
http://pschmid.net/blog/2006/09/18/43
***
Customize Office 2007: http://pschmid.net/office2007/customize
RibbonCustomizer Add-In: http://pschmid.net/office2007/ribboncustomizer
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed


Thank you for the help. I really appreciate it.

Regards,
Neil Goundar

Patrick Schmid [MVP] wrote:
I think you are out of luck. Your better bet is to look into accessing
the signatures and their insertion from the Outlook object model. I
don't do anything with Outlook that goes beyond the ribbon, so I'll
leave the question whether this is possible up to another replier.

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Office 2007 RTM Issues: http://pschmid.net/blog/2006/11/13/80
Office 2007 Beta 2 Technical Refresh (B2TR):
http://pschmid.net/blog/2006/09/18/43
***
Customize Office 2007: http://pschmid.net/office2007/customize
RibbonCustomizer Add-In: http://pschmid.net/office2007/ribboncustomizer
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed

" wrote in message
ups.com:

Hello all,

I need to insert a signature into an E-mail through code in Outlook
2007.

Does anyone know how I may be able to execute one of the Signatures
from the Signature menu on the Ribbon?

I know about the ExecuteMso method, but how do I get the idMso for the
signatures that appear on the menu when a new signature is inserted on
the Signature menu?

I am inserting a custom signature into the menu and and I need to
insert the signature into any new inspector when it opens up.

In Outlook 2003, i was able to Find the commandbars object for the
signature menu (using FindControl(ID)) and then loop through the
commandbars collection to check the captions of the buttons and execute
the button with my custom signature.

How would I be able to achieve this in Outlook 2007?

Thank you for any help in advance.

Regards,
Neil Goundar.


 




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
Rendering problems & no RIBBON with beta 2007 Cardslinger Outlook - Installation 1 August 12th 06 07:32 PM
Outlook Form Command Button Code Tipcie Outlook and VBA 1 July 26th 06 02:26 PM
Customizing the Ribbon in Outlook 2007 Chad Harris Outlook - General Queries 0 June 23rd 06 03:01 PM
Outlook 2007 - why no ribbon? Daern's Instant Fortress Outlook - General Queries 1 May 24th 06 05:56 PM
click a button on the toolbar (via VBA?) Dan Outlook - General Queries 2 May 1st 06 01:39 PM


All times are GMT +1. The time now is 06:52 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.