Thread: 'm_dlgColor' : undeclared identifier in B.cpp error....

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Registered User
    Join Date
    Mar 2009
    Posts
    48
    i guess i already understand what you said. thanks!
    And furthermore questions.

    A.h
    Code:
    Public:
    COLORREF   m_dlgColor;
    // declare the member at head file.

    A.cpp
    [code]
    class ObjectA {
    public:
    int m_intA;
    // Q1, What's the different Or reason, if i declare member of "m_dlgColor" here ?
    void bob_functionA(void);
    };



    B.h
    Code:
    Public:
    COLORREF   m_dlgColorObjectB;
    B.cpp
    Code:
    class ObjectB {
        public:
            int m_intB;
            void bob_functionB(void);
            {
             // Q2: try to initialization Or Asign value via the following statement ?
             m_dlgColorObjectB = ObjectA.m_dlgColor
            }
            
    };
    Q3. Does the bob_functionB() Could be filled outside of Class ObjectB? What's the different between fill the member function inside the class or outside of the class?

    :-)
    Last edited by userpingz; 06-08-2009 at 09:59 PM. Reason: bold font for the question items
    --------------------------------------------------------
    Newbie
    C/C#/C++
    swimming/cycling/running
    There is nothing more powerful than an idea.
    Except for an idea put into action.
    --------------------------------------------------------

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Compiling sample DarkGDK Program
    By Phyxashun in forum Game Programming
    Replies: 6
    Last Post: 01-27-2009, 03:07 AM
  2. Quantum Random Bit Generator
    By shawnt in forum C++ Programming
    Replies: 62
    Last Post: 06-18-2008, 10:17 AM
  3. Making C DLL using MSVC++ 2005
    By chico1st in forum C Programming
    Replies: 26
    Last Post: 05-28-2008, 01:17 PM
  4. Question..
    By pode in forum Windows Programming
    Replies: 12
    Last Post: 12-19-2004, 07:05 PM
  5. UNICODE and GET_STATE
    By Registered in forum C++ Programming
    Replies: 1
    Last Post: 07-15-2002, 03:23 PM