Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Docking Pane
  New Posts New Posts RSS Feed - docking pane layout to XML does not work!
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

docking pane layout to XML does not work!

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


Joined: 13 May 2003
Location: United States
Status: Offline
Points: 48
Post Options Post Options   Thanks (0) Thanks(0)   Quote spike Quote  Post ReplyReply Direct Link To This Post Topic: docking pane layout to XML does not work!
    Posted: 21 June 2005 at 8:51am

I am trying to save docking pane layouts to an xml file, this used to work in the 9.50 version of the toolkit. With the latest version 9.601 this no longer works. It only saves 1 layout per XML file.

I am kind of curious why you switched from using MSXML to write the file to using CStdioFile, I believe this is part of the problem.

Has there been a fix to this?

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: 21 June 2005 at 1:35pm

Here code you can use:

to save:

CXTPPropExchangeXMLNode px(FALSE, 0, _T("Settings"));

CXTPPropExchangeSection pxLayout1(px.GetSection(_T("Layout1")));

pLayout1->DoPropExchange(&pxLayout1);

CXTPPropExchangeSection pxLayout1(px.GetSection(_T("Layout2")));

pLayout2->DoPropExchange(&pxLayout2);

px.SaveToFile(m_strIniFileName);

 

to load:

CXTPPropExchangeXMLNode px(TRUE, 0, _T("Settings")); // To serialize to XML file

if (px.LoadFromFile(m_strIniFileName))

{

   

CXTPPropExchangeSection pxLayout1(px.GetSection(_T("Layout1")));

pLayout1->DoPropExchange(&pxLayout1);

CXTPPropExchangeSection pxLayout1(px.GetSection(_T("Layout2")));

pLayout2->DoPropExchange(&pxLayout2);


}

Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
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.157 seconds.