![]() |
Tab Toolbar Click Event |
Post Reply ![]() |
Author | |
Rod001 ![]() Newbie ![]() Joined: 29 September 2006 Location: United States Status: Offline Points: 25 |
![]() ![]() ![]() ![]() ![]() Posted: 20 March 2007 at 12:35pm |
Hello. I am using CommandBars Contol (10.4.2) with the following code to create a tab that will execute an event to show different calendar views. I am not sure if this is correct or even possible. Please any help would be appreciated.
Thank you.
![]() Private Sub CreateToolBar()
Dim Control As CommandBarControl 'Removes the menu bar and all toolbars CommandBars.DeleteAll 'Re-Add the Menu Bar ' CommandBars.AddMenuBar "Menu" ' commandbars. 'Add a Tabbed ToolBar Set TabToolBar = CommandBars.AddTabToolBar("Standard Tabbed Toolbar") '("Standard", xtpBarTop) Dim toolbarTab As TabControlItem '************************************ 'Add Categories to the Tabbed ToolBar '************************************ 'Add the "Standard" Category Set toolbarTab = TabToolBar.InsertCategory(ID_TAB_DAY, "Day") toolbarTab.Image = ID_DAY_ICON 'Add the "Advanced" Category Set toolbarTab = TabToolBar.InsertCategory(ID_TAB_WORKWEEK, "WorkWeek") toolbarTab.Image = ID_WORKWEEK_ICON 'Add the "Other" Category Set toolbarTab = TabToolBar.InsertCategory(ID_TAB_WEEK, "Week") toolbarTab.Image = ID_WEEK_ICON 'Add the "User Tools" Category Set toolbarTab = TabToolBar.InsertCategory(ID_TAB_MONTH, "Month") toolbarTab.Image = ID_MONTH_ICON 'setup tabs parameters TabToolBar.MinimumWidth = 400 TabToolBar.TabPaintManager.BoldSelected = True TabToolBar.ShowExpandButton = False TabToolBar.ShowGripper = False TabToolBar.TabPaintManager.Appearance = xtpTabAppearanceVisualStudio2005 TabToolBar.ContextMenuPresent = False TabToolBar.AllowReorder = False TabToolBar.EnableDocking xtpFlagAlignLeft ' TabToolBar.Customizable = False End Sub |
|
![]() |
|
moe188 ![]() Senior Member ![]() Joined: 27 March 2006 Status: Offline Points: 220 |
![]() ![]() ![]() ![]() ![]() |
Hi,
Why don't you use the commandbar to creat toolbar with 4 buttons (Day view, Work Week, Week, Month), then add calendar control to your form, and everytime you click a button in your toolbar, the view of the calendar control will change.
|
|
![]() |
|
Rod001 ![]() Newbie ![]() Joined: 29 September 2006 Location: United States Status: Offline Points: 25 |
![]() ![]() ![]() ![]() ![]() |
Hi moe,
Thanks for the response.
Per your suggestion I used the commandbar and it worked out great.
Thanks again for the help. ![]() |
|
![]() |
|
moe188 ![]() Senior Member ![]() Joined: 27 March 2006 Status: Offline Points: 220 |
![]() ![]() ![]() ![]() ![]() |
Hi Rod, it works fine for me, you can check the attached file, and let me know if that what you are trying to do. |
|
![]() |
|
Rod001 ![]() Newbie ![]() Joined: 29 September 2006 Location: United States Status: Offline Points: 25 |
![]() ![]() ![]() ![]() ![]() |
Moe,
Thanks for the example, it confirmed that I was started in the right direction.
|
|
![]() |
Post Reply ![]() |
|
Tweet
|
Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |