Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: VC6 VC7 VC7.1 C++ Visual-Studio MFC , +
Hi guy,
My tool bar work fine with limited buttons on it like,
i have 20 buttons on of 30x30 size then ok, my tool bar works fine,
Problem arised when my number of buttons on tool bar increase,
like,
If my toolbar have 90 buttons on it then more than 20 buttons cross the mainframe window.
so user cannot access those button that place outside the main frame.
 
________________________________________________________
so provide me any link,succestion or block of code that allows me to solve this problem.
 
Thanks and regard.
santosh dhanawade.
Posted 17-Dec-12 0:50am
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

This is not a good design, 90 buttons in a single toolbar is just going to confuse people. You should either use multiple toolbars, or the new Ribbon style bars as used in the newer Microsoft Office products. Take a look at these links[^] for help on using the Ribbon.
  Permalink  
Comments
Maximilien at 17-Dec-12 6:44am
   
The current framework (MFC?) does restrict the number of buttons on the toolbar; The user can (if enabled) even customize his toolbars to add more buttons.
Richard MacCutchan at 17-Dec-12 6:46am
   
I'm not sure why you are telling me this.
Coder Block at 18-Dec-12 6:43am
   
90 button needed ..
I gives a option of customize tool bar ..
but user cross the frame wnd by showing lots of buttons then??
Richard MacCutchan at 18-Dec-12 8:12am
   
Then you have to do the same thing that Windows office does, and have a drop down button at the end of the bar that holds all the buttons that cannot be displayed. Or, you can use the Ribbon toolbar, as I suggested above. Or, you can look at your design and figure out why you need all these buttons.
Coder Block at 19-Dec-12 1:09am
   
hmm but i am using studio 2003 server edition ..
i dont get control like ribbon in it??
or may be i am wrong.
Richard MacCutchan at 19-Dec-12 4:18am
   
OK, so you cannot use the Ribbon option, that leaves you to investigate the other method.
Coder Block at 20-Dec-12 6:32am
   
do you have any alternative?
Richard MacCutchan at 20-Dec-12 6:36am
   
I have explained what the alternatives are, now it is up to you to investigate them and decide which you can use. If you believe there may be others then I would suggest some Google searching.
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

I'm not in front of a Windows OS right now, but I think the MFC framework adds a little "drop-down" button at the right of the toolbar that will open a menu of some kind displaying the buttons that cannot be displayed.
 
Have a look at the CMFCToolbar documentation.
  Permalink  
Comments
Coder Block at 18-Dec-12 6:42am
   
how to do that??

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 277
1 Maciej Los 240
2 DamithSL 200
3 Raul Iloc 185
4 Richard MacCutchan 175
0 OriginalGriff 5,130
1 DamithSL 4,197
2 Maciej Los 3,670
3 Kornfeld Eliyahu Peter 3,470
4 Sergey Alexandrovich Kryukov 2,821


Advertise | Privacy | Mobile
Web02 | 2.8.141216.1 | Last Updated 17 Dec 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100