Toolbar with different buttons |
Post Reply |
Author | |
skiman
Groupie Joined: 20 December 2008 Location: Belgium Status: Offline Points: 88 |
Post Options
Thanks(0)
Posted: 17 February 2010 at 5:30am |
Hi,
I'm testing the toolbar functionalities with Codejock. I don't succeed to do the following. As you can see I have 3 types of buttons. I don't succeed to get them in one toolbar. It should be easy with a ribbonbar, but I need it at the left or right. A ribbonbar can only be top or bottom? I tried the following: Create a commandbar. Add a toolbar with an iconsize of 32,32 Add a toolbar with an iconsize of 12,12 The result is that I have 2 toolbars, they are not on the same commandbar. They behave as two different toolbars. Anyone who can point me in the right direction? Best regards, Chris. |
|
ABO Service
|
|
Aaron
Senior Member Joined: 29 January 2008 Status: Offline Points: 2192 |
Post Options
Thanks(0)
|
Hi,
It can be done with just a commandbars Toolbar. See image, the buttons are checked so you can see the height & width
Set toolBarItems = CommandBars.Add("Gereedschap", xtpBarLeft)
toolBarItems.Width = 75 Set btn = AddButton(toolBarItems.Controls, xtpControlButton, 40, " F1", False, "", xtpButtonIconAndCaption, "Gereedschap", False) btn.Width = 75 btn.Height = 75 btn.SetIconSize 32, 32 btn.Checked = True Set btn = AddButton(toolBarItems.Controls, xtpControlButton, 40, " F2", False, "", xtpButtonIconAndCaption, "Gereedschap", False)
btn.Width = 25 btn.Height = 16 btn.SetIconSize 16, 16 btn.Checked = True and so on....
just keep the total width of the horizontal buttons equal to the width of the toolbar
|
|
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2 Language: Visual Basic 6.0 Zero replies is not an option.... |
|
skiman
Groupie Joined: 20 December 2008 Location: Belgium Status: Offline Points: 88 |
Post Options
Thanks(0)
|
Hi,
Thanks, I will try this right away. Regards, |
|
ABO Service
|
|
skiman
Groupie Joined: 20 December 2008 Location: Belgium Status: Offline Points: 88 |
Post Options
Thanks(0)
|
Hi,
I don't succeed. ... ... I can't find ADDButton, I only find the ADD method? With the Width and Height, the buttons are changed, but they won't appear near each other, they all become under each other. They are on one toolbar, but I can't position them. Any other thoughts? Starting a new group? Or something else? Regards, Chris. |
|
ABO Service
|
|
shipwreck
Senior Member Joined: 18 April 2008 Location: United States Status: Offline Points: 308 |
Post Options
Thanks(0)
|
Hello Skiman, The addbutton method is a function defined in many of the projects using the ribbon. Check your sample projects under Ribbon for this custom function.
Hope that helps friend ;] |
|
Product: Xtreme Suite Pro (Active-X), Version 15.3.1
Platform: Windows 7 Ultimate SP1 (64Bit) & Windows XP Mode SP3 (32Bit) Language: Visual Basic 6.0 SP6 |
|
Aaron
Senior Member Joined: 29 January 2008 Status: Offline Points: 2192 |
Post Options
Thanks(0)
|
Hi,
I think you have to try something else... This isn't going to work like you would expect. If the toolbar is docked you get a different layout, I don't know why but the toolbar is resized differently and the buttons are aligned somehow. Undocked it looks just what you want but that is not enough, right? You have to find other solution to create such toolbar.
Good luck
|
|
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2 Language: Visual Basic 6.0 Zero replies is not an option.... |
|
skiman
Groupie Joined: 20 December 2008 Location: Belgium Status: Offline Points: 88 |
Post Options
Thanks(0)
|
Hi,
Yes, you are correct. When the toolbar is floating, it looks as I want. It looks as a bug to me. I can't imagine that this behaviour is normal.
Thanks for your remark. Now I know why it isn't working in my Xbase++ sample.
Regards,
Chris.
|
|
ABO Service
|
|
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 |