Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Property Grid
  New Posts New Posts RSS Feed - Can not create my CXTPPropertyGridView
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Can not create my CXTPPropertyGridView

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


Joined: 15 November 2004
Status: Offline
Points: 18
Post Options Post Options   Thanks (0) Thanks(0)   Quote Sergey Quote  Post ReplyReply Direct Link To This Post Topic: Can not create my CXTPPropertyGridView
    Posted: 06 April 2005 at 2:54am

I need to override method CXTPPropertyGrid::CreateView() in order to get notification on CXTPPropertyGridView Set/Kill focus events. However I can not create my view as described below. Unfortunately we can not release our product until we resolve the problem.

I created class CXTPPropertyGridEx : public CXTPPropertyGrid

and added virtual CXTPPropertyGridView* CreateView() to it.

The method CreateView is called from CXTPPropertyGrid construcor. At this point my CXTPPropertyGridEx object was not created yet. That is why the method CXTPPropertyGrid::CreateView() is called rather than CXTPPropertyGridEx::CreateView(). So my CreateView() is not called and I can not create my view and catch events.

What is wrong?

Thank you in advance.

Sergey

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: 06 April 2005 at 4:25am

Sorry we didn't test it for this. We will fix it in next release

please change it as:

1. make m_pView protected

2. add in constructor of CXTPPropertyGridEx

if (m_pView != NULL)

{   

   delete m_pView;

   m_pView = CreateView();
}

Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
Sergey View Drop Down
Newbie
Newbie


Joined: 15 November 2004
Status: Offline
Points: 18
Post Options Post Options   Thanks (0) Thanks(0)   Quote Sergey Quote  Post ReplyReply Direct Link To This Post Posted: 06 April 2005 at 5:28am

Hi,

Thank you for quick reply.

I think the same problem exists for CXTPPropertyGridPaintManager that is created in CXTPPropertyGrid constructor. So it must be deleted later when we create own Paint Manager.

Sergey.

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.156 seconds.