N
noone
Hello all,
Below is a snippet of code that I using in my first attempt at a COM object.
All is working fine, my question is how do I control the placement of the
custom toolbar, i.e. now it is right after the New button.
I would like to have it go after the users 'Organize' button, or if not
present
at the end of the Standard toolbar.
I've been googlin for an hour now, any help is appreciated.
Thanks.
Dim oExp As Outlook.Explorer
Dim oBar As Office.CommandBar
Set oExp = Outlook.ActiveExplorer
Set oBar = oExp.CommandBars.Item("Standard")
Set myControl = oBar.FindControl(, , "Unsolicited")
If myControl Is Nothing Then
Set myControl = oBar.Controls.Add(, , , 2, True)
With myControl
.Caption = "Unsolicited"
.FaceId = 67
.Style = msoButtonIconAndCaption
.Tag = "Unsolicited"
.Visible = True
End With
End If
Below is a snippet of code that I using in my first attempt at a COM object.
All is working fine, my question is how do I control the placement of the
custom toolbar, i.e. now it is right after the New button.
I would like to have it go after the users 'Organize' button, or if not
present
at the end of the Standard toolbar.
I've been googlin for an hour now, any help is appreciated.
Thanks.
Dim oExp As Outlook.Explorer
Dim oBar As Office.CommandBar
Set oExp = Outlook.ActiveExplorer
Set oBar = oExp.CommandBars.Item("Standard")
Set myControl = oBar.FindControl(, , "Unsolicited")
If myControl Is Nothing Then
Set myControl = oBar.Controls.Add(, , , 2, True)
With myControl
.Caption = "Unsolicited"
.FaceId = 67
.Style = msoButtonIconAndCaption
.Tag = "Unsolicited"
.Visible = True
End With
End If