Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Docking Pane
  New Posts New Posts RSS Feed - Dynamic Pane(ActiveX) 8.6
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Dynamic Pane(ActiveX) 8.6

 Post Reply Post Reply
Author
Message
robs View Drop Down
Groupie
Groupie


Joined: 09 November 2003
Status: Offline
Points: 84
Post Options Post Options   Thanks (0) Thanks(0)   Quote robs Quote  Post ReplyReply Direct Link To This Post Topic: Dynamic Pane(ActiveX) 8.6
    Posted: 14 January 2004 at 11:16am

Is there any way to dynamicly add a pane? I would consider the way the panes are added in the SDISample static. You know ahead of time which panes are to be added so you write code to add them. But if you write more code to add another pane, it won't add unless the entire section for the dockingpanes is deleted from the registry.

For example:

1. Run the SDI Sample

2. Stop the sample and add code to add another pane

3. Run the SDI Sample again. The pane isn't added unless you manually whack all of the registry settings for your app from the registry.

Am I doing something wrong?

thanks

 

Back to Top
robs View Drop Down
Groupie
Groupie


Joined: 09 November 2003
Status: Offline
Points: 84
Post Options Post Options   Thanks (0) Thanks(0)   Quote robs Quote  Post ReplyReply Direct Link To This Post Posted: 14 January 2004 at 1:02pm

Oleg,

If I manually go into the registry and increase the Client key by 1 for each new pane I add, it seems to work. Is this a bug or normal behavior?

So, I follow the 3 steps listed above, but before step 3, I modify the registry, and it seems to work.

thanks

 

Back to Top
robs View Drop Down
Groupie
Groupie


Joined: 09 November 2003
Status: Offline
Points: 84
Post Options Post Options   Thanks (0) Thanks(0)   Quote robs Quote  Post ReplyReply Direct Link To This Post Posted: 16 January 2004 at 2:04pm

Can someone tell me if this is normal? Pretty simple question.

Recap:

If you add a new docking pane to a project, it will only show if:

A. It's the first time you are running the project

or

B. You manualy delete the Docking pane entrys from the registry

 

Is this correct?

Back to Top
Oleg View Drop Down
Admin Group
Admin Group
Avatar

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: 18 January 2004 at 11:23pm

You must manually control of adding new pane.

If you release your softwate with 3 panes and the next version must have 4 panes you must change registry key of you Layout setting:

DockingPaneManager.LoadState "Codejock Software Demos", "SDISample", "Layout.version2"
DockingPaneManager.SaveState "Codejock Software Demos", "SDISample", "Layout.version2"

Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
robs View Drop Down
Groupie
Groupie


Joined: 09 November 2003
Status: Offline
Points: 84
Post Options Post Options   Thanks (0) Thanks(0)   Quote robs Quote  Post ReplyReply Direct Link To This Post Posted: 16 February 2004 at 7:27pm

I think I figured out a way to get arround this, incase anyone is wondering. If you need to create dynamic panes, or there is the potential to:

1. Have your application create more panes than needed to start out with.

2. If you ever add functionality to your app that needs a new pane, just grab one of the IDs you used for one of those extra panes.

This appears to be working for me. The plus side is that if I need to add a new pane in the future, I can without first using .DestroyAll first. This way, the panes our clients have been working with maitain there settings. Make sense?

I added 100 extra as a test and the system resources didn't change much. I'm hoping that because the extra panes don't yet have an associated .handle, they aren't using much memory.

 

Back to Top
JSram View Drop Down
Groupie
Groupie


Joined: 22 October 2004
Status: Offline
Points: 42
Post Options Post Options   Thanks (0) Thanks(0)   Quote JSram Quote  Post ReplyReply Direct Link To This Post Posted: 25 October 2004 at 8:03am
Hi,

I just came onboard and wonder if this still is the case? I can understand the logic in this for a ready and released application, but during the development phase you only knows how many panes you are going to end up with in a perfect world and I think few of us live in such a one... so some kind of flexability in the IDE could be useful here.

As I'm new to the control I can't say I fully understand and knows how to use it yet, but if you avoid to load and save state during development util you know "this will be it", does it introduce any particular problems?

However, the ability to dynamicly load and unload panes, at least in a group, would be a welcome feature. Much like you can do with a dynamic menu. I'm working on an app that could make good use of this and will try robs suggestion above, but are a bit unclear of exactly how you mean to do it rob? Do you mean to just "CreatePane" but never attach the ones not needed at startup or?

The app I'm working on it displays a kind of "document" on startup, although it a drawing of a diagram actuall. This drawing can be replaced with and new drawing, based on other data. I originally designed this to pupup as a form, but putting it in a pane Gave me some ideas and one is that the second or even third drawing comes up in a new pane and they are nicely tabbed to switch between, or even an other pane were two drawings are merged with each other into a new drawing.

But question is then as well if a pane can be "detached"?


Edited by JSram
Back to Top
robs View Drop Down
Groupie
Groupie


Joined: 09 November 2003
Status: Offline
Points: 84
Post Options Post Options   Thanks (0) Thanks(0)   Quote robs Quote  Post ReplyReply Direct Link To This Post Posted: 06 November 2004 at 8:01am

JSram,

Here's how I'm handeling dynamic panes to work with my plug-in architecture. Some code is omited, but you should be able to get the general idea.

1. Create a temporary data type to store pane information when plug-ins add panes.

2. If a plug-in adds a pane, fill TempPane and add it to a collection.

3. *After* all plug-ins are loaded, load the dockingstate for the dockingpane manager.

4. Compare collection to dockingpane manager. Load new panes as needed, destroy old panes as needed.

*EDIT* removed code and posted sample project

2004-11-06_115324_DockSample.zip



Edited by robs
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down



This page was generated in 0.078 seconds.