Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Docking Pane
  New Posts New Posts RSS Feed - Yet Another Pane Width Problem
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Yet Another Pane Width Problem

 Post Reply Post Reply
Author
Message
jcollier View Drop Down
Senior Member
Senior Member


Joined: 15 February 2006
Status: Offline
Points: 250
Post Options Post Options   Thanks (0) Thanks(0)   Quote jcollier Quote  Post ReplyReply Direct Link To This Post Topic: Yet Another Pane Width Problem
    Posted: 28 February 2006 at 10:59am
After reviewing previous posts about pane width, none of them seem to work with simply setting the width of a pane and having it show at that width.  It seems that many problems would be answered ahead of time if there were a pane.width and pane.height property that we could just set to what we want and have the pane resize to that property value.

That said, what I am trying to do is show a form on a pane.  That works fine.  However, when the user checks a checkbox, I want the form and the pane to widen out to show more options.  When they uncheck it, I want it to go back to it's original width.  However, the following code isn't quite working:

Set a = frmParent.DockingPaneManager.FindPane(3)
a.MinTrackSize.SetSize 690, 620
frmParent.DockingPaneManager.RedrawPanes

It does change the mintracksize but if I want the pane to show at that width, I have to manually resize it with the mouse.

Any suggestions?

Thanks!
Back to Top
SuperMario View Drop Down
Admin Group
Admin Group
Avatar

Joined: 14 February 2004
Status: Offline
Points: 18057
Post Options Post Options   Thanks (0) Thanks(0)   Quote SuperMario Quote  Post ReplyReply Direct Link To This Post Posted: 28 February 2006 at 11:09am
check this post out...first set the min and max to the same value to resize the pane, then change it to allow resize:

https://forum.codejock.com/forum_posts.asp?TID=3602&KW=n ormalize
Back to Top
jcollier View Drop Down
Senior Member
Senior Member


Joined: 15 February 2006
Status: Offline
Points: 250
Post Options Post Options   Thanks (0) Thanks(0)   Quote jcollier Quote  Post ReplyReply Direct Link To This Post Posted: 28 February 2006 at 12:06pm
Yeah, I saw that post.  That's where I originally saw the .RedrawPanes line.  However, I guess I should have mentioned that this is a floating pane and is never docked.

I tried the following:

Set a = frmParent.DockingPaneManager.FindPane(3)
a.MinTrackSize.SetSize 690, 620
a.MinTrackSize.SetSize 690, 620
frmParent.DockingPaneManager.RedrawPanes

but the form still does not resize on it's own.  It does act a little differently now in that if I click on the edge of the form when I have the resize cursor it jumps to the specified size.  Still doesn't do it without the mouse though.
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 28 February 2006 at 12:34pm
You can set this Track Sizes in Form_Load and after make it floating.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
jcollier View Drop Down
Senior Member
Senior Member


Joined: 15 February 2006
Status: Offline
Points: 250
Post Options Post Options   Thanks (0) Thanks(0)   Quote jcollier Quote  Post ReplyReply Direct Link To This Post Posted: 28 February 2006 at 12:39pm
I'm not sure how that helps.  When the user clicks the check box I want the form/pane to expand.  If they uncheck the check box it needs to go back to the smaller size.  I'm confused at how anything in Form_Load would affect the pane getting resized after it's not docked.
Back to Top
SuperMario View Drop Down
Admin Group
Admin Group
Avatar

Joined: 14 February 2004
Status: Offline
Points: 18057
Post Options Post Options   Thanks (0) Thanks(0)   Quote SuperMario Quote  Post ReplyReply Direct Link To This Post Posted: 28 February 2006 at 1:52pm
if floating then:

    Set A = DockingPaneManager.FindPane(3)
    DockingPaneManager.FloatPane A, 0, 0, 692, 620
Back to Top
jcollier View Drop Down
Senior Member
Senior Member


Joined: 15 February 2006
Status: Offline
Points: 250
Post Options Post Options   Thanks (0) Thanks(0)   Quote jcollier Quote  Post ReplyReply Direct Link To This Post Posted: 28 February 2006 at 2:02pm
Beautiful!

That works.  Thanks!
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.156 seconds.