Problem with the reference to (CTreeCtrlEx)

Discussion in 'C' started by rag84dec, Jun 15, 2009.

  1. rag84dec

    rag84dec New Member

    Jul 17, 2007
    Likes Received:
    Trophy Points:
    I have an MFC dialog which has a Tree(CTreeCtrlEx) structure where each node is a combo box.
    I want to have a "Cancel" button which will cancel the option chosen by the user and goes with
    the user chosen previosly.I have a cancel button but,as soon as the user changes the (CTreeCtrlEx)
    item,the values will be changed.

    Now all i want is to store the previous option and compared to DoModal return.and use the oprions

    Currently, i am doing like this ,i have mentioned below
    OC_Dlg_PureMFC_Test_Options_c is a subclass of CTreeCtrlEx
    OC_Dlg_PureMFC_Test_Options_c(m_Options).DoModal();  // m_Options is a reference...
    How will i save the previous m_Options?....Any idea?
    I tried doing the following ...

    OC_TestOptions_Common_c *temp = new OC_TestOptions_Common_c(m_Options);
    OC_Dlg_PureMFC_Test_Options_c(m_Options).DoModal();  // m_Options is a reference...

    But i dont know how to turn it back to m_Options... can any one help me??

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice