I'm wondering if there is a way of programmatically opening an Outlook Shortcut from my addin.
I've created the shortcut as follows
Sub AddShortcut()
Dim myOlBar As Outlook.OutlookBarPane
Dim myolGroup As Outlook.OutlookBarGroup
Dim myOlShortcuts As Outlook.OutlookBarShortcuts
myOlBar = Application.ActiveExplorer.panes.Item("OutlookBar")
myolGroup = myOlBar.Contents.Groups.Item(1)
myOlShortcuts = myolGroup.Shortcuts
myOlShortcuts.Add("http://microsoft.com/", _
"MSHomepage", 1)
End Sub
I'm guessing I need to use InvokeMember
in some way
myOlShortcuts("MSHomepage").GetType().InvokeMember(..)
But when I use GetType().GetMethods()
I can't see any Click
members or something similar. Any help is very much appreciated.