Click here to Skip to main content
15,913,055 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: How read CD-ROM disc data? Pin
Trollslayer28-Jun-03 5:26
mentorTrollslayer28-Jun-03 5:26 
GeneralRe: How read CD-ROM disc data? Pin
kakan30-Jun-03 21:23
professionalkakan30-Jun-03 21:23 
GeneralMsComm control in User ActiveX Pin
rarao27-Jun-03 18:00
rarao27-Jun-03 18:00 
GeneralRe: MsComm control in User ActiveX Pin
Trollslayer28-Jun-03 5:33
mentorTrollslayer28-Jun-03 5:33 
Questionhow to deal with this error?(about SHGetFolderLocation) Pin
tiplip27-Jun-03 15:55
tiplip27-Jun-03 15:55 
AnswerRe: how to deal with this error?(about SHGetFolderLocation) Pin
Toni7827-Jun-03 16:14
Toni7827-Jun-03 16:14 
GeneralRe: how to deal with this error?(about SHGetFolderLocation) Pin
tiplip27-Jun-03 16:21
tiplip27-Jun-03 16:21 
GeneralRe: how to deal with this error?(about SHGetFolderLocation) Pin
Toni7827-Jun-03 16:26
Toni7827-Jun-03 16:26 
I don't know then. This is what I got from MSDN on the error:

Compiler Error C2065
'identifier' : undeclared identifier

The specified identifier was not declared.

A variable’s type must be specified in a declaration before it can be used. The parameters that a function uses must be specified in a declaration, or prototype, before the function can be used.

Tips

Make sure any include file containing the required declaration is not omitted.


Make sure you are including any necessary header files if you have defined VC_EXTRALEAN, WIN32_LEAN_AND_MEAN, or WIN32_EXTRA_LEAN. Defining these symbols excludes some functionality (certain header files are excluded) from windows.h and afxv_w32.h (for MFC applications) to speed compiles. Search windows.h and afxv_w32.h for these symbols for the most up-to-date description of what is excluded.


Make sure the identifier name is spelled correctly.


Make sure the identifier is using the correct upper- and lowercase letters.


Make sure all string constants have closing quotes.


This error can be caused by having a newline character in a string constant without a continuation character. For example:
#include <stdio.h>
main() {
printf("\n %s
%s // error: 's' : undeclared identifier
%s",
"this", "is", "it");
}

Special considerations must be taken when splitting a constant string over several lines. The most common method is to change the format string. Strings separated only by whitespace (spaces, tabs, newlines) are concatenated. For example:
#include <stdio.h>
main() {
printf("\n %s"
" %s"
" %s",
"this", "is", "it");
}

An older, less-preferred method is to use line continuation by typing a backslash at the end of a line. For example:
printf("\n %s\
%s\
%s",
"this", "is", "it");

This method is not often used because the spaces at the beginning of each continued line become part of the string.

Make sure you're using proper namespace scope. For example, in order to properly resolve ANSI C++ Standard Library functions and operators, you must state that you're using the std namespace with the using directive.
For example, unless the using directive is uncommented, the following sample will fail to compile because the cout stream is defined in the std namespace:

#include <iostream>
// using namespace std;
void main()
{
cout << "Hello" << endl;
}



// Afterall, I realized that even my comment lines have bugs

When one cannot invent, one must at least improve (in bed).-My latest fortune cookie
AnswerRe: how to deal with this error?(about SHGetFolderLocation) Pin
Ryan Binns27-Jun-03 16:58
Ryan Binns27-Jun-03 16:58 
GeneralRe: how to deal with this error?(about SHGetFolderLocation) Pin
Anonymous27-Jun-03 23:09
Anonymous27-Jun-03 23:09 
AnswerRe: how to deal with this error?(about SHGetFolderLocation) Pin
Michael Dunn27-Jun-03 17:21
sitebuilderMichael Dunn27-Jun-03 17:21 
QuestionHow can I use ReadFile() and WriteFile () Pin
Angel Kid27-Jun-03 14:44
Angel Kid27-Jun-03 14:44 
AnswerRe: How can I use ReadFile() and WriteFile () Pin
Toni7827-Jun-03 15:25
Toni7827-Jun-03 15:25 
GeneralRe: How can I use ReadFile() and WriteFile () Pin
Angel Kid28-Jun-03 1:33
Angel Kid28-Jun-03 1:33 
GeneralRe: How can I use ReadFile() and WriteFile () Pin
Toni7828-Jun-03 9:47
Toni7828-Jun-03 9:47 
GeneralRe: How can I use ReadFile() and WriteFile () Pin
louis30-Jun-03 2:35
louis30-Jun-03 2:35 
AnswerRe: How can I use ReadFile() and WriteFile () Pin
valikac28-Jun-03 6:57
valikac28-Jun-03 6:57 
GeneralPowerPoint File Processing w/out office automation? $$$ Pin
RickGavin27-Jun-03 12:46
RickGavin27-Jun-03 12:46 
GeneralRe: PowerPoint File Processing w/out office automation? $$$ Pin
Ryan Binns27-Jun-03 17:03
Ryan Binns27-Jun-03 17:03 
GeneralMatrix! HELP!!!! Pin
Sunnygirl27-Jun-03 11:23
Sunnygirl27-Jun-03 11:23 
GeneralRe: Matrix! HELP!!!! Pin
valikac27-Jun-03 11:27
valikac27-Jun-03 11:27 
GeneralRe: Matrix! HELP!!!! Pin
Anonymous28-Jun-03 9:28
Anonymous28-Jun-03 9:28 
GeneralRe: Matrix! HELP!!!! Pin
valikac28-Jun-03 9:37
valikac28-Jun-03 9:37 
GeneralRe: Matrix! HELP!!!! Pin
Dominik Reichl27-Jun-03 20:59
Dominik Reichl27-Jun-03 20:59 
GeneralRe: Matrix! HELP!!!! Pin
Anonymous28-Jun-03 9:29
Anonymous28-Jun-03 9:29 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.