![]() |
slider control on toolbar |
Post Reply ![]() |
Author | |
JamesP ![]() Groupie ![]() ![]() Joined: 07 January 2009 Location: United Kingdom Status: Offline Points: 73 |
![]() ![]() ![]() ![]() ![]() Posted: 12 January 2009 at 11:27am |
Could someone tell me how to add a slider control on the toolbar. We would like to have our zoom control there with a + and - button.
I've got code like this:
CSliderCtrl wndSliderCtrl;
wndSliderCtrl.Create(TBS_HORZ | WS_CHILD | WS_VISIBLE, CRect(0, 0, 200, 16), &m_wndStatusBar, IDC_SLIDER);
m_wndStatusBar.AddIndicator(ID_INDICATOR_SLIDER, iIndex);
int nIndex = m_wndStatusBar.CommandToIndexID_INDICATOR_SLIDER);
m_wndStatusBar.SetPaneWidth(nIndex, 200);
m_wndStatusBar.SetPaneStyle(nIndex, m_wndStatusBar.GetPaneStyle(nIndex) | SBPS_NOBORDERS);
m_wndStatusBar.AddControl(&m_wndSliderCtrl, ID_INDICATOR_SLIDER, FALSE);
This produces a slider control with the normal grey background rather than the Office2007 theme I'm using. Should I be using CXTPControlSlider?
I've seen reference to using CXTPControlScrollBar with a slider style in version 12 but we only have version 11.2.
Any help would be greatly appreciated.
|
|
![]() |
|
Oleg ![]() Senior Member ![]() Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
![]() ![]() ![]() ![]() ![]() |
Hi,
With 11.2 you can only use standard slider that will have gray background. :(
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
JamesP ![]() Groupie ![]() ![]() Joined: 07 January 2009 Location: United Kingdom Status: Offline Points: 73 |
![]() ![]() ![]() ![]() ![]() |
I upgraded to version 12 and that gave me the solution with examples that I needed, thanks.
|
|
![]() |
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 |