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

Tab Text

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


Joined: 31 August 2006
Status: Offline
Points: 12
Post Options Post Options   Thanks (0) Thanks(0)   Quote TerryT Quote  Post ReplyReply Direct Link To This Post Topic: Tab Text
    Posted: 31 August 2006 at 10:34am

I take solace in the fact we were all newbies once…

I would like to change the tab text that is displayed for a document opened in a CXTPMDIFrameWnd
yet the document title and document path are to remain as is

I have the desired text at document creation time:

// create/open document
if((pDoc = pDocTemplate->OpenDocumentFile("fred.txt")) != NULL)
{
    // locate newly created view
    POSITION pos = pDoc->GetFirstViewPosition();

    . . .

but the tab CXTPTabManagerItem is not available (is yet to be created?)  from CXTPTabClientWnd

what is the message/event to the MainFrame that signals a tab has been added?

I searched all forums/examples/et al to no avail

I’m assuming I’ll need to create a new msg/command to be sent to the active view to set the tab text?
or, can this be accomplished possibly in OnInitialUpdate() for the first view
or
Please point me in the right direction

Thanks!

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: 31 August 2006 at 10:38am
Hello,
CXTPTabClientWnd send WM_XTP_GETWINDOWTEXT message to CChildFrame to get tab text. Catch it and return LPCTSTR with text.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
TerryT View Drop Down
Newbie
Newbie


Joined: 31 August 2006
Status: Offline
Points: 12
Post Options Post Options   Thanks (0) Thanks(0)   Quote TerryT Quote  Post ReplyReply Direct Link To This Post Posted: 31 August 2006 at 11:30am
You Rock!
 
Thanks for the quick reply!
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.048 seconds.