![]() |
Disable Docking |
Post Reply
|
| Author | |
denczek
Newbie
Joined: 06 August 2004 Status: Offline Points: 27 |
Post Options
Thanks(0)
Quote Reply
Topic: Disable DockingPosted: 21 April 2006 at 1:24pm |
|
In a CXTMDIChildWnd based class I have a CXTToolBar placed on the left side of a window using the following code in the OnCreate method: m_wndToolBar.EnableDocking(CBRS_ALIGN_ANY); Once the window appears with the toolbar docked on the left side of the window, I would like the toolbar to be stuck there so the user cannot drag it or undock it. How do I do this? |
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 21 April 2006 at 2:41pm |
|
Instead EnableDocking(CBRS_ALIGN_ANY); try CBRS_ALIGN_TOP |
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
denczek
Newbie
Joined: 06 August 2004 Status: Offline Points: 27 |
Post Options
Thanks(0)
Quote Reply
Posted: 21 April 2006 at 3:16pm |
|
I changed the code in the OnCreate procedure from: m_wndToolBar.EnableDocking(CBRS_ALIGN_ANY); to m_wndToolBar.EnableDocking(CBRS_ALIGN_ANY); Unfortunately, all it did was move the toolbar to the top of the window and it was still detachable. |
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 21 April 2006 at 4:37pm |
|
Change first line also. m_wndToolBar.EnableDocking(CBRS_ALIGN_ANY); |
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
denczek
Newbie
Joined: 06 August 2004 Status: Offline Points: 27 |
Post Options
Thanks(0)
Quote Reply
Posted: 21 April 2006 at 5:00pm |
|
I changed the code in the OnCreate procedure from: m_wndToolBar.EnableDocking(CBRS_ALIGN_ANY); to m_wndToolBar.EnableDocking(CBRS_ALIGN_TOP); Unfortunately, I get the same results. |
|
![]() |
|
denczek
Newbie
Joined: 06 August 2004 Status: Offline Points: 27 |
Post Options
Thanks(0)
Quote Reply
Posted: 21 April 2006 at 5:07pm |
|
Now if I change the code to: m_wndToolBar.EnableDocking(CBRS_ALIGN_LEFT); The toolbar comes up docked on the left and I cannot drag the toolbar if I grip it and do a drag. But if I grip close to the single button I have on the toolbar, then it allows me to drag the toolbar and detach it. In this case I can only reattach it to the left side of the window. Ideally, I would like to not allow any way to detach the toolbar from the left side of the window.
|
|
![]() |
|
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 |