![]() |
Why Word toolbars are hidden when Outlook with WordMail is launche
Hi,
When launching an Outlook application that is configured to use WordMail as the default mail editor, a Word process is started in background. This word process will load my word addin that creates a toolbar and a popupmenubar. Unfortunately when I then open word (after opening Outlook as previously described), my toolbar is invisible while the popupmenu bar is visible. Can anybody explain to me what happens? Why Outlook hides the word toolbars? and what can be done other than making the toolbar visible in the WindowActivate event of Word. Note that this solution is not satisfying since we force the visibility of the toolbar to true, while the user might wants to hide it!! I really don't want Outlook to hide the Word toolbar :( Thanks you very much for the answer... Hichem |
Why Word toolbars are hidden when Outlook with WordMail is launche
Handle WindowActivate events in Word object model code in both addins. Test
for wn.EnvelopeVisible = True. That means a WordMail window, False means a Word.Document window. You can iterate the CommandBars collections and set your Enabled and Visible properties as desired. I usually disable the custom Word toolbars in WordMail and vice versa. You also have to handle cases where more than one WordMail Inspector and/or more than one Document are open at a time so multiple copies of toolbars aren't visible. -- 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 "Hichem S" wrote in message ... Hi, When launching an Outlook application that is configured to use WordMail as the default mail editor, a Word process is started in background. This word process will load my word addin that creates a toolbar and a popupmenubar. Unfortunately when I then open word (after opening Outlook as previously described), my toolbar is invisible while the popupmenu bar is visible. Can anybody explain to me what happens? Why Outlook hides the word toolbars? and what can be done other than making the toolbar visible in the WindowActivate event of Word. Note that this solution is not satisfying since we force the visibility of the toolbar to true, while the user might wants to hide it!! I really don't want Outlook to hide the Word toolbar :( Thanks you very much for the answer... Hichem |
Why Word toolbars are hidden when Outlook with WordMail is lau
Sorry Ken but this does not answer my question...
I actually went through all you described but I am doing it a little bit different. I am actually hiding the outlook addin (using inspector.IsWordMail) and I am using the Word addin when it comes to handle WordMail (using EnvelopeVisible) : if the Envelope is visible then I treat the document as an email. If it's not i treat it as a word document. This solution allow me not to play with WindowActivate/Deactivate to hide and show the toolbars : In fact only one toolbar is created by application. I hope this will help to understand my question : When I open Outlook with wordmail configured (I don't open yet a word application), Outlook hides the toolbar created by the Word process that was launched in the backgroud (:wordmail). If then I open Word my toolbars are infact Invisible...what happened? "Ken Slovak - [MVP - Outlook]" wrote: Handle WindowActivate events in Word object model code in both addins. Test for wn.EnvelopeVisible = True. That means a WordMail window, False means a Word.Document window. You can iterate the CommandBars collections and set your Enabled and Visible properties as desired. I usually disable the custom Word toolbars in WordMail and vice versa. You also have to handle cases where more than one WordMail Inspector and/or more than one Document are open at a time so multiple copies of toolbars aren't visible. -- 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 "Hichem S" wrote in message ... Hi, When launching an Outlook application that is configured to use WordMail as the default mail editor, a Word process is started in background. This word process will load my word addin that creates a toolbar and a popupmenubar. Unfortunately when I then open word (after opening Outlook as previously described), my toolbar is invisible while the popupmenu bar is visible. Can anybody explain to me what happens? Why Outlook hides the word toolbars? and what can be done other than making the toolbar visible in the WindowActivate event of Word. Note that this solution is not satisfying since we force the visibility of the toolbar to true, while the user might wants to hide it!! I really don't want Outlook to hide the Word toolbar :( Thanks you very much for the answer... Hichem |
Why Word toolbars are hidden when Outlook with WordMail is lau
You need to handle things as I mentioned. It doesn't matter if you want to
hide or show a Word or WordMail toolbar in either setup, you have to do the same things. You have to iterate the CommandBars collection of the Word.Document object (Inspector.WordEditor for a WordMail object) and find the ones you want and enable/disable them as desired and set the visibility as desired. What Outlook and WordMail or Word on its own do on their own can be overridden by your code. You just have to set things up as desired. -- 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 "Hichem S" wrote in message ... Sorry Ken but this does not answer my question... I actually went through all you described but I am doing it a little bit different. I am actually hiding the outlook addin (using inspector.IsWordMail) and I am using the Word addin when it comes to handle WordMail (using EnvelopeVisible) : if the Envelope is visible then I treat the document as an email. If it's not i treat it as a word document. This solution allow me not to play with WindowActivate/Deactivate to hide and show the toolbars : In fact only one toolbar is created by application. I hope this will help to understand my question : When I open Outlook with wordmail configured (I don't open yet a word application), Outlook hides the toolbar created by the Word process that was launched in the backgroud (:wordmail). If then I open Word my toolbars are infact Invisible...what happened? |
Why Word toolbars are hidden when Outlook with WordMail is lau
Hi Ken,
Sorry to insist... My purpose with the last answer is to give you the more element you may need to answer my question. I want to add that my addin is a shared addin and in the connect I switch on the application object to decide for the right thing to do. As I said in my first comment it's unwanted to force the visibility of a toolbar to true if the user chose to set it to false!...What happens is that outlook sets the visibility of my toolbar to false which I NEVER DID IN MY CODE. In fact I never in any place set the visibility of the toolbar to false. I searched but I did not find any thread talking about this issue. This is understandable, since you always advice poeple to work on the mail item in wordmail from an outlook point of view which make this issue undetectable! "Ken Slovak - [MVP - Outlook]" wrote: You need to handle things as I mentioned. It doesn't matter if you want to hide or show a Word or WordMail toolbar in either setup, you have to do the same things. You have to iterate the CommandBars collection of the Word.Document object (Inspector.WordEditor for a WordMail object) and find the ones you want and enable/disable them as desired and set the visibility as desired. What Outlook and WordMail or Word on its own do on their own can be overridden by your code. You just have to set things up as desired. -- 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 "Hichem S" wrote in message ... Sorry Ken but this does not answer my question... I actually went through all you described but I am doing it a little bit different. I am actually hiding the outlook addin (using inspector.IsWordMail) and I am using the Word addin when it comes to handle WordMail (using EnvelopeVisible) : if the Envelope is visible then I treat the document as an email. If it's not i treat it as a word document. This solution allow me not to play with WindowActivate/Deactivate to hide and show the toolbars : In fact only one toolbar is created by application. I hope this will help to understand my question : When I open Outlook with wordmail configured (I don't open yet a word application), Outlook hides the toolbar created by the Word process that was launched in the backgroud (:wordmail). If then I open Word my toolbars are infact Invisible...what happened? |
Why Word toolbars are hidden when Outlook with WordMail is lau
I understand what you are saying and when Outlook does that you can leave it
as is or use your code to make your UI visible. You can save the last state of the UI (visible/invisible) when the item is closed in either version and use that later, but since Outlook is doing this you either have to live with it or you have to change things in your code. -- 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 "Hichem S" wrote in message ... Hi Ken, Sorry to insist... My purpose with the last answer is to give you the more element you may need to answer my question. I want to add that my addin is a shared addin and in the connect I switch on the application object to decide for the right thing to do. As I said in my first comment it's unwanted to force the visibility of a toolbar to true if the user chose to set it to false!...What happens is that outlook sets the visibility of my toolbar to false which I NEVER DID IN MY CODE. In fact I never in any place set the visibility of the toolbar to false. I searched but I did not find any thread talking about this issue. This is understandable, since you always advice poeple to work on the mail item in wordmail from an outlook point of view which make this issue undetectable! |
Why Word toolbars are hidden when Outlook with WordMail is lau
Thanks for your answer...
That's exactly what I am doing : save the last state of the UI = the only way i found to deal with the problem. But as this is a workaround, I just wanted to know if I can avoid outlook from doing what it does... and understand why...? If possible, can you tell me what happens? why outlook does that? Thanks "Ken Slovak - [MVP - Outlook]" wrote: I understand what you are saying and when Outlook does that you can leave it as is or use your code to make your UI visible. You can save the last state of the UI (visible/invisible) when the item is closed in either version and use that later, but since Outlook is doing this you either have to live with it or you have to change things in your code. -- 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 "Hichem S" wrote in message ... Hi Ken, Sorry to insist... My purpose with the last answer is to give you the more element you may need to answer my question. I want to add that my addin is a shared addin and in the connect I switch on the application object to decide for the right thing to do. As I said in my first comment it's unwanted to force the visibility of a toolbar to true if the user chose to set it to false!...What happens is that outlook sets the visibility of my toolbar to false which I NEVER DID IN MY CODE. In fact I never in any place set the visibility of the toolbar to false. I searched but I did not find any thread talking about this issue. This is understandable, since you always advice poeple to work on the mail item in wordmail from an outlook point of view which make this issue undetectable! |
Why Word toolbars are hidden when Outlook with WordMail is lau
I don't know why Outlook is doing that in your code and what the Outlook or
WordMail internals are. So your guess is as good as mine is. -- 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 "Hichem S" wrote in message ... Thanks for your answer... That's exactly what I am doing : save the last state of the UI = the only way i found to deal with the problem. But as this is a workaround, I just wanted to know if I can avoid outlook from doing what it does... and understand why...? If possible, can you tell me what happens? why outlook does that? Thanks |
All times are GMT +1. The time now is 12:32 PM. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2006 OutlookBanter.com