Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - CreateToolbar
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

CreateToolbar

 Post Reply Post Reply
Author
Message
slowsail View Drop Down
Newbie
Newbie


Joined: 17 September 2008
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote slowsail Quote  Post ReplyReply Direct Link To This Post Topic: CreateToolbar
    Posted: 09 April 2009 at 8:44pm
Hi,

I create a toolbar in a view with the codes,


       VERIFY(m_maskviewBar.CreateToolBar(WS_TABSTOP|WS_VISIBLE|WS_CHILD|CBRS_TOOLTIPS, this));
       VERIFY(m_maskviewBar.LoadToolBar(IDR_MASKVIEW_BAR));

       CXTPImageManager*  pImageManager = XTPImageManager();
       pImageManager->SetIcons(IDR_MASKVIEW_BAR, IDB_MASKVIEW_BAR_FOR_ADAPTIVEMESH);


And it's a dll project. The toolbar is generated properly



But it crashes when I click OK or Cancel to quit the DLL. It says "0x00000014" memory is can not be "read"...

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: 10 April 2009 at 1:23am
Hi,
Try in ExitInstance of your App of dll  add CXTPPaintManager::Done() and XTPImageManager()->RemoveAl();
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
slowsail View Drop Down
Newbie
Newbie


Joined: 17 September 2008
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote slowsail Quote  Post ReplyReply Direct Link To This Post Posted: 10 April 2009 at 2:17am
oleg,

Thanks for your kindly help. But it still crashes.

I also confirm that it's not problem of CXTPImageManager. Actually the crash is still there after I comment the following two line of codes,

///////////////////////////////////
       CXTPImageManager*  pImageManager = XTPImageManager();
       pImageManager->SetIcons(IDR_MASKVIEW_BAR, IDB_MASKVIEW_BAR_FOR_ADAPTIVEMESH);
///////////////////////////////////

It seems that CreateToolBar() or LoadToolBar() generates the crash.
Back to Top
slowsail View Drop Down
Newbie
Newbie


Joined: 17 September 2008
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote slowsail Quote  Post ReplyReply Direct Link To This Post Posted: 12 April 2009 at 8:39pm
I traced the codes, it breaks here.



BTW: I use Extreme Toolkit pro 12.02.
Intel Q6600
Windows XP SP3
Extreme Toolkit pro 12.02
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.047 seconds.