Solved

....\Tables.cpp(1615) : error C2065: 'gIdle' : undeclared identifier

Posted on 2003-12-04
3
314 Views
Last Modified: 2010-04-02
Hi,
When trying to make a build from C++ source code I get the following message:
Compiling resources...
Compiling...
blah...
.
.
.
blah...
....\Tables.cpp(1615) : error C2065: 'gIdle' : undeclared identifier

'gIdle' IS declared somewhere in the beginning of Tables.cpp. Besides, this is strange because I got a large chunk of code which is SUPPOSED to pass compilation without any problem.

Short project history: What happened is I got the source code and got access to large databases that interface header files can be found in. But the project files RGui.dsp and RGui.dsw were missing information, so I had to build the links myself pointing to the paths where the needed header files are located. When now building, it no longer tells me files are missing, but rather gives me the above **undeclared identifier** message.

Any help will be much appreciated,
Giora
0
Comment
Question by:gimozes
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 49

Accepted Solution

by:
DanRollins earned 250 total points
ID: 9878900
>> 'gIdle' IS declared somewhere in the beginning of Tables.cpp

The fact that you say "somewhere" indicates that you are not sure where.  You will need to track down the declaration and be 100% certain that it is declared.  I'll wager that it is declared in a .h file that is not #included at the top of Tables.cpp

That coulkd happen in the case you describe.  The original project dsw could have specified a particular INCLUDE path and your default INCLUDE path is bringing in a different version of the .H that provides the declaration.  Use the IDE's 'Search in Files' to locate all references to that variable.  That usually shakes loose problems like these.

Another thing that can happen:  
It is possible for the precompiled header to get out of date in a few strange circumstances.  But that is eacy to fix:  Do a Clean before the Bild.  I assume you've done that, but It's worth mentioning.

One other common problem:  You may have mispelled it!
    gIdle looks a lot like
    gldle which looks a lot like
    gldIe and so forth.

-- Dan
0
 
LVL 5

Expert Comment

by:migoEX
ID: 10364877
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

Accept DanRollins's comment as answer.

Please leave any comments here within the next four days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

migoEX
EE Cleanup Volunteer
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Templates For Beginners Or How To Encourage The Compiler To Work For You Introduction This tutorial is targeted at the reader who is, perhaps, familiar with the basics of C++ but would prefer a little slower introduction to the more ad…
Written by John Humphreys C++ Threading and the POSIX Library This article will cover the basic information that you need to know in order to make use of the POSIX threading library available for C and C++ on UNIX and most Linux systems.   [s…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question