Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Docking Pane
  New Posts New Posts RSS Feed - Dropdown not staying dropped
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Dropdown not staying dropped

 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: Dropdown not staying dropped
    Posted: 14 February 2008 at 10:05am
I have a form (not a mdi child).  On the form is a Frame.  In the frame is a dropdown with x number of values.  When I load the form into a DockingPane, the dropdown won't stay down and allow me to choose a value.  I've tried putting the dropdown directly on the form (outside the Frame).  I've tried putting the dropdown in a picturebox.  I've tried putting the frame in a picturebox.  All attempts were unsuccessful. 

In a related item, the checkboxes that are also in the Frame are not checkable.  I click them but nothing happens.

Hopefully the fix is simple.

Anyone?

Thanks!
Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 14 February 2008 at 2:04pm
Hi,
 
If you load the form without attaching it to a pane, what happens then? Does it work correctly? Yes? and how do you attach the form to the pane?
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: 14 February 2008 at 2:21pm
As a test I used the SDI Docking Pane sample and added both MS and Codejock checkbox and dropdown controls to the form.  Both seem to work.  Can you reproduce it with a Codejock sample?  If so, can you attach it here?
Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 14 February 2008 at 2:37pm
Hi,
 
No can't reproduce it, but I would like to know the code you use to attach the pane to that form. Can you send me the form and the few lines of code you use to attach the pane? doesn't matter anymore, now Super Mario comes in action
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: 14 February 2008 at 2:46pm
Actually, I recreated my situation in a new project with everything stripped down.  VB6 with CJ 11.2.2

This project is just as I have mine set up.  MDI Parent loads mdi child which attaches form to pane.

uploads/20080214_144611_dropdown.zip

Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 14 February 2008 at 3:10pm
Hi,
 
It's a little difficult to explain. But I will give it a try.
 
The container for your app is the MDIForm and the dockingpane will be the container for all the attached panes, right? So you have to place the Dockingpane in the MDIForm and attach the form that you need into a pane, which DockingPane will resize into you MDIForm the proper way. Not in a way you did. 
 
 
Put this in your MDIForm code and drag a DockingPane on the MDIForm
I copied your code into the MDIForm and the only thing I changed was the Load event in MDIForm
 
Option Explicit
Private Sub DockingPane1_AttachPane(ByVal Item As XtremeDockingPane.IPane)
    Dim frmForm2 As Form2
    Set frmForm2 = New Form2
    Item.Handle = frmForm2.hWnd
           
End Sub

Private Sub CreateDashboard()
    Dim paneForm2 As Pane
   
    Set paneForm2 = DockingPane1.CreatePane(1, 100, 100, DockTopOf, Nothing)
    paneForm2.Title = "Messages"
    ''paneForm2.Options = PaneNoFloatable + PaneNoCloseable + PaneNoHideable
   
    DockingPane1.VisualTheme = ThemeOffice2007
    DockingPane1.Options.HideClient = True
   
    DockingPane1.TabPaintManager.ClientFrame = xtpTabFrameNone
   
End Sub
Private Sub MDIForm_Load()
Call CreateDashboard
End Sub
 
This will show a pane with the combobox on it and this combobox drops down as we want to.
 
And another thing: set MDIChild to false
And clear all code in Form1
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: 14 February 2008 at 3:38pm
Cool.  Now the curveball.  Let's say I have a button on Form2 that just loads and shows form1.  How do I make the pane go to the background?  As it is now, Form2 loads and shows but it "shows" behind the pane and I can't see Form2.

Sorry for all the questions but I appreciate the help!
Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 14 February 2008 at 3:50pm
Hi,
 
Do you want to close the pane? or temporary hide the pane?
 
You can auto hide the pane by docking it and clicking on the pin button
 
Close the pane like this:
 
Dim pan As XtremeDockingPane.Pane
        Set pan = MDIForm1.DockingPane1.FindPane(1) ''ID of pane
            pan.Close
 
Back to Top
Aaron View Drop Down
Senior Member
Senior Member
Avatar

Joined: 29 January 2008
Status: Offline
Points: 2192
Post Options Post Options   Thanks (0) Thanks(0)   Quote Aaron Quote  Post ReplyReply Direct Link To This Post Posted: 14 February 2008 at 3:57pm

Hi,

Are you going to build a MDI application? There's a MDI sample present, you better take a look at that and post a little here and there, pulling out hair, but there's an example present

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: 14 February 2008 at 4:35pm
Actually, I would like it to just kinda be the background of the mdi parent and automatically be visible when no other mdi children are open.
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: 15 February 2008 at 8:51am
Originally posted by jcollier jcollier wrote:

Actually, I recreated my situation in a new project with everything stripped down.  VB6 with CJ 11.2.2

This project is just as I have mine set up.  MDI Parent loads mdi child which attaches form to pane.

uploads/20080214_144611_dropdown.zip



The problem is with Focus.  The MDIChild doesn't have any control on it.  VB wants a control on the MDIChild, it needs some control on it to have focus.  This is just a bug in VB.

So it would be better to move your Frame over to Form1 and remove Form2.
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.188 seconds.