Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#160 ActiveContent issue

v2.3
open
nobody
None
5
2009-06-06
2009-06-06
Ulysess
No

Set Pane.ActiveContent or call DockPanel.LoadFromXml should set/restore which DockContent is active, but for Document dockarea if write these thing in constructor of main form (which hold DockPanel), results funny behavior. See attachment project, every time app execute the active document will change. Set Pane.ActiveContent has same problem.

But all right with these code in form's Load event.

Discussion

  • Ulysess
    Ulysess
    2009-06-06

    demo project

     
    Attachments
  • stfx
    stfx
    2009-10-04

    Yeah this issue is very annoying. Would be awesome if someone can fix it.

    More info:
    - The ActiveDocumentChanged event is fired multiple times at loading. It would be better if it just fires once after it has finished to load all document.
    - The last ActiveDocumentChanged event has the correct active document but the dockpanel still shows the first document every time.

    thanks

     
  • stfx
    stfx
    2009-10-04

    Well just found a workaround your problem.

    Put the DockPanel.LoadFromXml function call in Form_Load event.