Object Unideclared Identifier

This is a discussion on Object Unideclared Identifier within the C++ Programming forums, part of the General Programming Boards category; OK I am creating an instance of class 1 Lift Lift1 in another class and I am trying to access ...

  1. #1
    Registered User
    Join Date
    Jan 2004
    Posts
    68

    Object Unideclared Identifier

    OK I am creating an instance of class 1 Lift Lift1 in another class and I am trying to access its public function using

    Lift1.blah;

    however its saying Undeclared Identifier.
    -Ti22-

  2. #2
    Anti-Poster
    Join Date
    Feb 2002
    Posts
    1,399
    I'm sorry...my psychic abilities are a bit off today. Could you post some code and show us where the problem is? If blah is a function of Lift, then you'll need some () unless you're really trying to get a function pointer.
    If I did your homework for you, then you might pass your class without learning how to write a program like this. Then you might graduate and get your degree without learning how to write a program like this. You might become a professional programmer without knowing how to write a program like this. Someday you might work on a project with me without knowing how to write a program like this. Then I would have to do you serious bodily harm. - Jack Klein

  3. #3
    30 Helens Agree neandrake's Avatar
    Join Date
    Jan 2002
    Posts
    640
    Just to elaborate on pianorain's post,

    Lift1.blah();
    Environment: OS X, GCC / G++
    Codes: Java, C#, C/C++
    AOL IM: neandrake, Email: neandrake (at) gmail (dot) com

  4. #4
    Registered User
    Join Date
    Jan 2004
    Posts
    68
    ok we fixed that now i am getting this problem

    LiftSystem error LNK2019: unresolved external symbol _main referenced in function _mainCRTStartup

    LiftSystem fatal error LNK1120: 1 unresolved externals
    -Ti22-

  5. #5
    Anti-Poster
    Join Date
    Feb 2002
    Posts
    1,399
    Are you missing an int main() somewhere? I couldn't tell you, since you still haven't posted any code.
    If I did your homework for you, then you might pass your class without learning how to write a program like this. Then you might graduate and get your degree without learning how to write a program like this. You might become a professional programmer without knowing how to write a program like this. Someday you might work on a project with me without knowing how to write a program like this. Then I would have to do you serious bodily harm. - Jack Klein

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. An error is driving me nuts!
    By ulillillia in forum C Programming
    Replies: 5
    Last Post: 04-04-2009, 09:15 PM
  2. Another syntax error
    By caldeira in forum C Programming
    Replies: 31
    Last Post: 09-05-2008, 01:01 AM
  3. Game Pointer Trouble?
    By Drahcir in forum C Programming
    Replies: 8
    Last Post: 02-04-2006, 01:53 AM
  4. Why wont my function exit correctly?
    By LightsOut06 in forum C Programming
    Replies: 2
    Last Post: 10-09-2005, 09:23 PM
  5. A question about constructors...
    By Wolve in forum C++ Programming
    Replies: 9
    Last Post: 05-04-2005, 04:24 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21