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 » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Custom Commandbar doesn't appear when opening or creating a new email



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old July 18th 06, 10:42 AM posted to microsoft.public.outlook.program_vba
Karsten_Markmann
external usenet poster
 
Posts: 4
Default Custom Commandbar doesn't appear when opening or creating a new email

Hey there
I have created this custom commandbar which works ok in the main
outlook window.
The problem is that this custom commandbar does not appear when I click
"new email" or opening an existing email. I do NOT use Word as email
editor.
Have anybody any ideas?

I have used the following code:

On Error Resume Next
Set cbrNewToolbar = Application.ActiveExplorer.CommandBars("Kunden
i Centrum2")
If Err = 0 Then ' Toolbar findes, så gør den lige synlig.
cbrNewToolbar.Delete 'slet baren for at undgå en masse
checkbøvl senere
Set cbrNewToolbar = Application.ActiveExplorer.CommandBars.Add
_
(Name:="Kunden i Centrum2", Position:=msoBarTop,
Temporary:=True)
Else
Set cbrNewToolbar = Application.ActiveExplorer.CommandBars.Add
_
(Name:="Kunden i Centrum2", Position:=msoBarTop,
Temporary:=True)
End If


Set cmbSaveEmailKiC =
cbrNewToolbar.Controls.Add(Type:=msoControlButton)
With cmbSaveEmailKiC
.FaceId = 271
.BeginGroup = False
.Visible = True
.Style = msoButtonIconAndCaption
.Caption = "Gem email i KiC"
.OnAction = "KundeKorrespondance"
.TooltipText = "Gem email på debitor i KiC systemet"
End With

cbrNewToolbar.Visible = True

  #2  
Old July 18th 06, 12:31 PM posted to microsoft.public.outlook.program_vba
Michael Bauer
external usenet poster
 
Posts: 435
Default Custom Commandbar doesn't appear when opening or creating a new email

Am 18 Jul 2006 02:42:42 -0700 schrieb Karsten_Markmann:

Karsten, in that case you need to create the bar for
ActiveInspector.Commandbars instead of Explorer.

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
-- www.VBOffice.net --


Hey there
I have created this custom commandbar which works ok in the main
outlook window.
The problem is that this custom commandbar does not appear when I click
"new email" or opening an existing email. I do NOT use Word as email
editor.
Have anybody any ideas?

I have used the following code:

On Error Resume Next
Set cbrNewToolbar = Application.ActiveExplorer.CommandBars("Kunden
i Centrum2")
If Err = 0 Then ' Toolbar findes, så gør den lige synlig.
cbrNewToolbar.Delete 'slet baren for at undgå en masse
checkbøvl senere
Set cbrNewToolbar = Application.ActiveExplorer.CommandBars.Add
_
(Name:="Kunden i Centrum2", Position:=msoBarTop,
Temporary:=True)
Else
Set cbrNewToolbar = Application.ActiveExplorer.CommandBars.Add
_
(Name:="Kunden i Centrum2", Position:=msoBarTop,
Temporary:=True)
End If


Set cmbSaveEmailKiC =
cbrNewToolbar.Controls.Add(Type:=msoControlButton)
With cmbSaveEmailKiC
.FaceId = 271
.BeginGroup = False
.Visible = True
.Style = msoButtonIconAndCaption
.Caption = "Gem email i KiC"
.OnAction = "KundeKorrespondance"
.TooltipText = "Gem email på debitor i KiC systemet"
End With

cbrNewToolbar.Visible = True

  #3  
Old July 19th 06, 06:26 AM posted to microsoft.public.outlook.program_vba
Karsten_Markmann
external usenet poster
 
Posts: 4
Default Custom Commandbar doesn't appear when opening or creating a new email

Thanks a lot Michael. That was a big help.

Michael Bauer skrev:

Am 18 Jul 2006 02:42:42 -0700 schrieb Karsten_Markmann:

Karsten, in that case you need to create the bar for
ActiveInspector.Commandbars instead of Explorer.

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
-- www.VBOffice.net --


 




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
Custom CommandBar in Wordmail Editor. Sanjay Add-ins for Outlook 0 May 31st 06 10:11 PM
Creating a custom appointment form Theresa Smallwood Outlook and VBA 11 May 15th 06 03:47 PM
Creating Custom Events Theresa Smallwood Outlook - General Queries 0 May 9th 06 04:07 PM
Creating new Appointment out of Custom Form Marc Herbrik Outlook and VBA 2 May 8th 06 03:38 PM
how to add a custom button on the explorer "standard" commandbar Herve cadieu Outlook and VBA 1 March 17th 06 03:33 PM


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