error C2059: syntax error : '->'
Hi
So im a bit lost in my c++ programming. Not the code init self, but a error I keep getting. I dont know why I keep getting -> error?
Im using Visual Studio ultimate 2010, and I havnt had any problem with it, til now:
Does anyone know why I keep gettin this error or possibly can be written some other way?
Error 1 error C2059: syntax error : '->'
Greatly appreciated! :)
Re: error C2059: syntax error : '->'
Re: error C2059: syntax error : '->'
Thanks, but Ive gone through all those, I couldnt find anything on www. This is my only option.
I need help with this error: Error 1 error C2059: syntax error : '->'
Am i typing -> wrong? Or does Visual Studio ultimate 2010 use some other way?
Thanks in advance
Re: error C2059: syntax error : '->'
Quote:
Originally Posted by
Maygon
Thanks, but Ive gone through all those, I couldnt find anything on www. This is my only option.
I need help with this error: Error 1 error C2059: syntax error : '->'
Am i typing -> wrong? Or does Visual Studio ultimate 2010 use some other way?
:(
Didn't you read my answer? :confused:
Quote:
Originally Posted by
VictorN
and, please, use Code tags when you you will post any code snippets!
Re: error C2059: syntax error : '->'
I need someone to help me with this error of mine.
http://speedy.sh/kEjM3/Syntax-error.png
I dont need help with any coding, just an explanation of why this might be happening.
Quite frustrating because i´ve never had any problems writting....... ->.......in any codes of c++ softwares that ive used like codeblocks or dev c++.
Thanks again
Re: error C2059: syntax error : '->'
Sh,,,t! :(
If you do need some help - show the code causing the problem, not the link to something that does not belong to this Forum.
Besides, it is not clear what symbols and from what code page do you use in "->" expression. So, again: post your exact code (use copy/paste, not just typing it in the edit window)
Re: error C2059: syntax error : '->'
Quote:
Originally Posted by
Maygon
I need someone to help me with this error of mine.
http://speedy.sh/kEjM3/Syntax-error.png
I dont need help with any coding, just an explanation of why this might be happening.
Quite frustrating because i´ve never had any problems writting....... ->.......in any codes of c++ softwares that ive used like codeblocks or dev c++.
Thanks again
Good grief dude, how do you expect anybody to tell you what you're doing wrong if you don't show us what you're doing?!?
Re: error C2059: syntax error : '->'
Quote:
I dont need help with any coding, just an explanation of why this might be happening.
In your program, you are using -> in a context for which the compiler does not accept -> as a valid symbol.
If the line containing the -> is supposed to be used correctly but the compiler is reporting a problem, I would look at the code before the line reporting the error for problems - or with the variable definition.
As others have pointed out, to provide further specific guidance you need to post the code containing the error line.
Re: error C2059: syntax error : '->'
Quote:
Originally Posted by
Maygon
I dont need help with any coding, just an explanation of why this might be happening.
It is happening because you're using -> where it shouldn't be used.
Quote:
Quite frustrating because i´ve never had any problems writting....... ->.......in any codes of c++ softwares that ive used like codeblocks or dev c++.
C++ is a computer language that has rules. It isn't a book report where you just "write stuff", and it has nothing to do with codeblocks or dev-C++. Your code violates a C++ rule in some way, and the only way to know is to see the code.
Regards,
Paul McKenzie
Re: error C2059: syntax error : '->'
Quote:
Originally Posted by
Maygon
I dont need help with any coding, just an explanation of why this might be happening.
Just an explanation of why: Compiler Error C2059
In two words, you put token -> where it does not belong.