It supports basic stuff, like icon-view and report-view. Multiple panels can be added, and they slide up and down when you click on them. There is no support for item renaming or repositioning.
The control got a little more complex than needed. Mostly because it's really three separate controls. Used together, they form a single Outlook control. However, each control can be used on its own.
The Outlook PaneThis is the actual Outlook list - displaying text and icons and sending notifications to the top-level window when items are clicked. Items are arranged as a list.
After creating the control, new items can be added by using the
InsertItem()method. Add both a small- and large-icon
SetImageList()method. To toggle between icons- and report-mode, use the
It is really a subclassed
ListBoxcontrol which is ownerdrawn (variable height).
The Outlook PagerThis control behaves much like the standard Windows Pager control. The control is used with a window that does not have enough display area to show all of its content. The control allows the user to scroll to the area of the window that is not currently in view.
The differences from the standard Pager control is, that the scroll buttons are attached on the right side of the view, and they look like ordinary push buttons.
It works just like the standard Pager control. That is, just use the
SetChild()method to attach a window. Moreover, the Pager control sends out a
PGN_CALCSIZEnotification to its parent - asking it to measure and return the recommended size of the child view.
The Outlook Bar controlThe Outlook Bar control act as containers for child windows. The control can contain one or more views, each presented with a header bar and a text label. The Outlook Bar control manages the size and position of the views assigned to it. Views scroll into place when the user clicks on the headers.
Any window can be added to it as a view, thus allowing you to add any custom control or widget. Only one window can be attached to a view.
It's really a
ReBarcontrol behind the scene, and each view is simply created as a new ReBar Band.
How to use itThe control is designed to be used in a view - and not particular for placement in a dialog. Because there are three controls in all, it is a little more complex to initialize than usual.
The control does not require the
macros because of its high need to be added to a splitter-type view.
The sample should show you how to build a simple Outlook bar with two panes.
Notice in the sample how the Outlook Pane is put inside an Outlook Pager control - allowing the Pane to be scrolled when it no longer fits the view.
Source Code DependenciesMicrosoft Visual C++ 6.0
Microsoft WTL 7.0 Library
See AlsoThe similar MS Access Bar control
|Source Code and sample (56 Kb)|