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

CommandBarButton::Enabled



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old May 5th 08, 04:50 PM posted to microsoft.public.outlook.program_addins
MON205[_2_]
external usenet poster
 
Posts: 33
Default CommandBarButton::Enabled

Hello all,
In my add-in I create a toolbar and set some buttons disabled. After some
actions I want to set these buttons enabled, so I set the Enabled property to
true. I noticed that sometimes these buttons still disabled until I point at
them (redraw problem). I think that the problem that setting the Enabled
property doesn't redraw the buttons.
What can I do to solve this?

Thanks a lot.
Ads
  #2  
Old May 6th 08, 03:25 PM posted to microsoft.public.outlook.program_addins
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default CommandBarButton::Enabled

What version of Outlook? Where is this toolbar, Explorers or Inspectors?
What code are you using?

--
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


"MON205" wrote in message
...
Hello all,
In my add-in I create a toolbar and set some buttons disabled. After some
actions I want to set these buttons enabled, so I set the Enabled property
to
true. I noticed that sometimes these buttons still disabled until I point
at
them (redraw problem). I think that the problem that setting the Enabled
property doesn't redraw the buttons.
What can I do to solve this?

Thanks a lot.


  #3  
Old May 6th 08, 05:01 PM posted to microsoft.public.outlook.program_addins
MON205[_2_]
external usenet poster
 
Posts: 33
Default CommandBarButton::Enabled

I'm using the _CommandBarButton::PutEnabled( VARIANT_TRUE );
in Outlook 2003.. The toolbar on explorer.

"Ken Slovak - [MVP - Outlook]" wrote:

What version of Outlook? Where is this toolbar, Explorers or Inspectors?
What code are you using?

--
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


"MON205" wrote in message
...
Hello all,
In my add-in I create a toolbar and set some buttons disabled. After some
actions I want to set these buttons enabled, so I set the Enabled property
to
true. I noticed that sometimes these buttons still disabled until I point
at
them (redraw problem). I think that the problem that setting the Enabled
property doesn't redraw the buttons.
What can I do to solve this?

Thanks a lot.



  #4  
Old May 7th 08, 01:04 AM posted to microsoft.public.outlook.program_addins
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default CommandBarButton::Enabled

I don't do C++, but I've never seen that with an Explorer button if the
Explorer has focus in any VB6, VB.NET or C# code. Does the Explorer have
focus? Is _CommandBarButton a valid object that is in scope?

--
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


"MON205" wrote in message
...
I'm using the _CommandBarButton::PutEnabled( VARIANT_TRUE );
in Outlook 2003.. The toolbar on explorer.


  #5  
Old May 8th 08, 10:20 AM posted to microsoft.public.outlook.program_addins
MON205[_2_]
external usenet poster
 
Posts: 33
Default CommandBarButton::Enabled

Hello Ken,
Yes, the Explorer has the focus and the button is valid.
The same problem also happen when I set an icon for the button (PutPicture).

"Ken Slovak - [MVP - Outlook]" wrote:

I don't do C++, but I've never seen that with an Explorer button if the
Explorer has focus in any VB6, VB.NET or C# code. Does the Explorer have
focus? Is _CommandBarButton a valid object that is in scope?

--
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


"MON205" wrote in message
...
I'm using the _CommandBarButton::PutEnabled( VARIANT_TRUE );
in Outlook 2003.. The toolbar on explorer.



  #6  
Old May 8th 08, 03:29 PM posted to microsoft.public.outlook.program_addins
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default CommandBarButton::Enabled

Well, I've never seen that happen in any of the addin I've worked on. As I
said, I don't do C++ but I've never seen it in any VB6, C# or VB.NET addins.
I'd still think it has to be something in how you're handling the code.

About the only thing I can think of is to test the scenario on a sample
addin written using C++, I think you can find one or two at
www.outlookcode.com.

--
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


"MON205" wrote in message
...
Hello Ken,
Yes, the Explorer has the focus and the button is valid.
The same problem also happen when I set an icon for the button
(PutPicture).


  #7  
Old May 11th 08, 09:44 AM posted to microsoft.public.outlook.program_addins
MON205[_2_]
external usenet poster
 
Posts: 33
Default CommandBarButton::Enabled

Thank you Ken.
I'll try doing that.

"Ken Slovak - [MVP - Outlook]" wrote:

Well, I've never seen that happen in any of the addin I've worked on. As I
said, I don't do C++ but I've never seen it in any VB6, C# or VB.NET addins.
I'd still think it has to be something in how you're handling the code.

About the only thing I can think of is to test the scenario on a sample
addin written using C++, I think you can find one or two at
www.outlookcode.com.

--
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


"MON205" wrote in message
...
Hello Ken,
Yes, the Explorer has the focus and the button is valid.
The same problem also happen when I set an icon for the button
(PutPicture).



 




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
CommandBarButton Picture, transparency Mike Add-ins for Outlook 1 September 26th 07 03:19 PM
add a picture to a CommandBarButton DavidH&P Outlook - Using Forms 0 August 30th 06 04:35 PM
How to add an Icon to a commandBarButton David Outlook and VBA 1 March 29th 06 06:39 PM
how to add commandbarbutton to inspector window Ram Outlook and VBA 0 January 19th 06 07:07 AM
how to add commandbarbutton to inspector window Ram Outlook - General Queries 1 January 18th 06 09:42 PM


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