[Help]I get these SYNTAX errors.Please Help

Posts 1–3 of 3 · Page 1 of 1
[Help]I get these SYNTAX errors.Please Help
I made an empty project.
I created a main.cpp file.

I have theses errors:

Code:
------ Build started: Project: wrhacker-1, Configuration: Debug Win32 ------

Compiling...
main.cpp
main.cpp(74) : error C2059: syntax error : 'if'
main.cpp(75) : error C2143: syntax error : missing ';' before '{'
main.cpp(75) : error C2447: '{' : missing function header (old-style formal list?)
main.cpp(79) : error C2059: syntax error : 'if'
main.cpp(80) : error C2143: syntax error : missing ';' before '{'
main.cpp(80) : error C2447: '{' : missing function header (old-style formal list?)
main.cpp(84) : error C2059: syntax error : 'if'
main.cpp(87) : error C2059: syntax error : 'if'
The Syntax error "if" and missing ";" before "{" and '{' : missing function header (old-style formal point to all my if.
Here is one of em ..

Code:
if(CH_On)
{
    MemFuncOn();
}
Any help on how to fix ???

on top I did ..

Code:
bool CH_On = false;
Thank you.
and again.. why you've posten it on 4 sites..

im thinking your really just added that code...you can't use a if-function in a cpp without a function (void...)

Code:
void Stuff()
{
   if(CH)
   {
      Blah();
   }
}
this is old lol ..
I fixed this.
Thnx for telling me to make a thread.
Posts 1–3 of 3 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

Need help?