CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Guest

    How do I get a pointer to a CPropertyPage's CPropertySheet?

    Hi,
    I have a CPropertySheet with two property pages.
    I need to read the text in an edit control in one page from the other page.
    If I could get a pointer to the property sheet from the page, I know what to do.
    But how do I get that pointer?

    Thanks
    D.B.


  2. #2
    Join Date
    May 1999
    Posts
    1

    Re: How do I get a pointer to a CPropertyPage's CPropertySheet?

    Use GetParent( ) and cast to CPropertySheet.


  3. #3
    Guest

    Re: How do I get a pointer to a CPropertyPage's CPropertySheet?

    Hi!

    U can use the function CWnd::GetParent() to get a pointer to the parent of the property pages and that will be the the property sheet. U can do this in the OnInitDialog() handler of either of the property pages. For this , however u will have to subclass the property page so as to be able to handle the WM_INITDIALOG message.

    HTH



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured