Limit Minimum size of CDockablePane<p>Hi guys,<br/>I am working on MDI VS-2008 aplication's Dockable pane and have to limit the minimum height and width of the pane.<br/><br/>For that, i tried to prevent it to CDockablepane::onsize() function's call in the OnSize function and to also overrided ON_WM_GETMINMAXINFO message.<br/><br/>but it didn't worked :(<br/><br/>Please help.<br/>Regards<br/>Harsh Shankar</p>© 2009 Microsoft Corporation. All rights reserved.Fri, 03 Jul 2009 09:04:59 Zc5c64126-8fd0-4614-9b08-7b59d7894a14http://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/c5c64126-8fd0-4614-9b08-7b59d7894a14#c5c64126-8fd0-4614-9b08-7b59d7894a14http://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/c5c64126-8fd0-4614-9b08-7b59d7894a14#c5c64126-8fd0-4614-9b08-7b59d7894a14Harsh Shankarhttp://social.msdn.microsoft.com/Profile/en-US/?user=Harsh%20ShankarLimit Minimum size of CDockablePane<p>Hi guys,<br/>I am working on MDI VS-2008 aplication's Dockable pane and have to limit the minimum height and width of the pane.<br/><br/>For that, i tried to prevent it to CDockablepane::onsize() function's call in the OnSize function and to also overrided ON_WM_GETMINMAXINFO message.<br/><br/>but it didn't worked :(<br/><br/>Please help.<br/>Regards<br/>Harsh Shankar</p>Mon, 29 Jun 2009 11:01:31 Z2009-06-29T11:01:31Zhttp://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/c5c64126-8fd0-4614-9b08-7b59d7894a14#17e488e3-dc6f-498b-881f-d38c2b4d3dd9http://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/c5c64126-8fd0-4614-9b08-7b59d7894a14#17e488e3-dc6f-498b-881f-d38c2b4d3dd9Wesley Yaohttp://social.msdn.microsoft.com/Profile/en-US/?user=Wesley%20YaoLimit Minimum size of CDockablePaneHi Harsh,<br/><br/>We could use CDockablePane::SetMinSize() method to limit the minimize size of the CDockablePane, i.e.: SetMinSize(CSize(100, 100)).<br/><br/>Sincerely,<br/>Wesley<hr class="sig">Please mark the replies as answers if they help and unmark them if they provide no help. <a href="http://cfx.codeplex.com/">Welcome to the All-In-One Code Framework!</a> If you have any feedback, please tell us.Wed, 01 Jul 2009 10:44:47 Z2009-07-01T10:44:47Zhttp://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/c5c64126-8fd0-4614-9b08-7b59d7894a14#aa2e23e0-37dc-4e97-b04a-d8009ddbf794http://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/c5c64126-8fd0-4614-9b08-7b59d7894a14#aa2e23e0-37dc-4e97-b04a-d8009ddbf794Harsh Shankarhttp://social.msdn.microsoft.com/Profile/en-US/?user=Harsh%20ShankarLimit Minimum size of CDockablePane<p>Hi Wesley,<br/>Thanks for replying.<br/>Sorry, but I already had tried it. but i don't know why it didn't worked.<br/>As i was trying <a href="http://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/d80c04c3-140c-443f-bb63-9ca3226fbdde">your answer of my one other post</a>, i got it working.<br/><br/>Thanks again<br/><br/> <hr class=sig> Regards<br/>Harsh<br/>VC++ Developer</p>Thu, 02 Jul 2009 16:35:49 Z2009-07-02T16:36:17Zhttp://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/c5c64126-8fd0-4614-9b08-7b59d7894a14#59985cea-bc2c-425e-aa44-f2b7e65a14b1http://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/c5c64126-8fd0-4614-9b08-7b59d7894a14#59985cea-bc2c-425e-aa44-f2b7e65a14b1Wesley Yaohttp://social.msdn.microsoft.com/Profile/en-US/?user=Wesley%20YaoLimit Minimum size of CDockablePaneHi Harsh,<br/><br/>Is it still does not work?  In my another post to your question, it's a work way.<br/>Maybe you have to delete the registry setting for it: search the name of your solution, delete its setting key.<br/><br/>Sincerely,<br/>Wesley<hr class="sig">Please mark the replies as answers if they help and unmark them if they provide no help. <a href="http://cfx.codeplex.com/">Welcome to the All-In-One Code Framework!</a> If you have any feedback, please tell us.Fri, 03 Jul 2009 05:07:16 Z2009-07-03T05:07:16Zhttp://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/c5c64126-8fd0-4614-9b08-7b59d7894a14#2d157638-ae80-4b7a-a50d-bbca01c6a310http://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/c5c64126-8fd0-4614-9b08-7b59d7894a14#2d157638-ae80-4b7a-a50d-bbca01c6a310Harsh Shankarhttp://social.msdn.microsoft.com/Profile/en-US/?user=Harsh%20ShankarLimit Minimum size of CDockablePane<p>Hi Wesley,<br/>I think one of my posts are missed that i posted just after reading your's other post and trying that..<br/>well, yes it worked but partially :(<br/>as i set the minimum size, it prevents from the resizing it to go less than the said but the problem i incountered is when some other Dockable pane is tabbed with it. even it is the active one but the minimum size have no limit<br/><br/>as snap of cade, you can your own code, since i have used the same.<br/><br/>thanks</p><hr class="sig">Regards Harsh VC++ DeveloperFri, 03 Jul 2009 06:46:50 Z2009-07-03T06:46:50Zhttp://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/c5c64126-8fd0-4614-9b08-7b59d7894a14#052ed677-37cd-4a58-a6f4-1ae9035896aehttp://social.msdn.microsoft.com/Forums/en-US/vcgeneral/thread/c5c64126-8fd0-4614-9b08-7b59d7894a14#052ed677-37cd-4a58-a6f4-1ae9035896aeWesley Yaohttp://social.msdn.microsoft.com/Profile/en-US/?user=Wesley%20YaoLimit Minimum size of CDockablePaneWell, when we dock a pane to another one, framework will generate a CTabbedPane which is the container for them, we will also need SetMinSize() for it.  The function to create this CTabbedPane is &quot;CreateTabbedPane()&quot;, you could try to override it and SetMinSize() in it, i.e.:<br/><br/> <pre lang="x-c#">CTabbedPane* MyDockablePane::CreateTabbedPane() { CTabbedPane* pTabbedBar = CDockablePane::CreateTabbedPane(); pTabbedBar-&gt;SetMinSize(CSize(200, 200)); //Here is that return pTabbedBar; }</pre> <br/><strong>Note</strong>: But we cannot modify the default CDockablePane's method, so when we dock a derived pane to a &quot;native CDockablePane&quot;, it will still act the result you've seen.<br/><br/>Sincerely,<br/>Wesley <hr class=sig> Please mark the replies as answers if they help and unmark them if they provide no help. <a href="http://cfx.codeplex.com/">Welcome to the All-In-One Code Framework!</a> If you have any feedback, please tell us.Fri, 03 Jul 2009 08:57:25 Z2009-10-26T10:21:58Z