Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - How to get the view in tab
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

How to get the view in tab

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


Joined: 01 December 2005
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote mqheather Quote  Post ReplyReply Direct Link To This Post Topic: How to get the view in tab
    Posted: 08 January 2006 at 7:45pm
I want to get the view in the tab,but CXTPTabManagerItem::GetHandle can't get it?? How can i do??Thank you!!
Back to Top
Oleg View Drop Down
Senior Member
Senior Member


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: 09 January 2006 at 10:10am

Hello,

GetHandle returns HWND, try

CWnd::FromHandle(pItem->GetHandle());

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


Joined: 01 December 2005
Status: Offline
Points: 7
Post Options Post Options   Thanks (0) Thanks(0)   Quote mqheather Quote  Post ReplyReply Direct Link To This Post Posted: 09 January 2006 at 7:58pm
but the hwnd returned didn't accord with the hwnd of view
Back to Top
Oleg View Drop Down
Senior Member
Senior Member


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: 11 January 2006 at 11:36am

ok, explain better what you do

CXTPTabManagerItem is tab of DockingPane, TabControl or TabWorkspace?

 

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

Joined: 21 September 2003
Location: Russian Federation
Status: Offline
Points: 28
Post Options Post Options   Thanks (0) Thanks(0)   Quote Russ Quote  Post ReplyReply Direct Link To This Post Posted: 11 January 2006 at 5:01pm
I think he's reffering to the CXTPTabControl which in turn is derived from CXTPTabManager.

I too faced this problem and ended up just saving the tab view's pointer in the parent view hosting the CXTPTabControl.

I too would like to know the recommended way of getting the view from the TabItem.
Back to Top
Russ View Drop Down
Groupie
Groupie
Avatar

Joined: 21 September 2003
Location: Russian Federation
Status: Offline
Points: 28
Post Options Post Options   Thanks (0) Thanks(0)   Quote Russ Quote  Post ReplyReply Direct Link To This Post Posted: 11 January 2006 at 5:06pm
Ok, just tried what Oleg suggested and it worked just fine.

CMyView* pView = (CMyView*)CWnd::FromHandle(pTabItem->GetHandle());


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.