Pane does not initially size correctly |
Post Reply |
Author | |
ijwelch
Senior Member Joined: 20 June 2006 Status: Offline Points: 262 |
Post Options
Thanks(0)
Posted: 29 August 2007 at 2:14am |
If I'm doing something stupid then please let me know...
I've got a 'find' dialog as a floating pane. The problem is that the very first time it's displayed it does not size correctly. Here's what it should look like: but the first time it's shown it looks like this: If the user attempts a resize it snaps to the correct size and always shows correctly thereafter. Here's my code for displaying the pane: Dim p As XtremeDockingPane.Pane Dim l As Long Dim t As Long 1000 If b Then 1010 Set p = dp.FindPane(DP_FIND) 1020 If p Is Nothing Then 1030 l = Me.Left / Screen.TwipsPerPixelX 1040 t = Me.Top / Screen.TwipsPerPixelY 1050 l = l + 32 1060 t = t + 100 1070 Set p = dp.CreatePane(DP_FIND, 399, 123, DockBottomOf, 1) 1080 p.Title = "Find..." 1090 p.Handle = ucFind.hwnd 1100 dp.FloatPane p, l, t, 399, 123 1110 p.Options = PaneNoDockable Or PaneNoHideable 1120 p.MinTrackSize.SetSize 399, 123 1130 p.MaxTrackSize.SetSize 399, 123 Else 1140 p.Handle = ucFind.hwnd 1150 p.Closed = False End If End If It's a bit hard to debug as one manual resize and everythings' ok again.. BTW this is using the latest version 11.1. Thanks in advance for any help. |
|
ijwelch
Senior Member Joined: 20 June 2006 Status: Offline Points: 262 |
Post Options
Thanks(0)
|
Sorry, posted in wrong section. This should be in activeX section. Can moderator please move?
|
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Hi,
Replace
dp.FloatPane p, l, t, 399, 123
to dp.FloatPane p, l, t, l + 399, t + 123
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
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 |