I am using VC++ 1.52, based on the tutorial doc, I copied all the CPP and H files into my project. I added the cpp files to my project and when I compiled I got C1010 error.
Please help.
Thanks.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Before doing any changes to the project, I was getting only 4 of the1010 error. I went to project and removed the stdafx from the precompiled headers and now I get arounf 399 errors; some of the errors are
include\tinystr.h(52) : error C2501: 'explicit' : missing decl-specifiers
include\tinystr.h(52) : error C2146: syntax error : missing ';' before identifier 'TiXmlString'
include\tinystr.h(63) : error C2501: 'explicit' : missing decl-specifiers
include\tinystr.h(63) : error C2146: syntax error : missing ';' before identifier 'TiXmlString'
/include\tinystr.h(111) : error C2501: 'bool' : missing decl-specifiers
include\tinystr.h(111) : error C2143: syntax error : missing ';' before 'operator <op>'
include\tinystr.h(111) : error C2240: unexpected 'const int ' following formal list (only modifiers are allowed)
include\tinystr.h(112) : error C2501: 'bool' : missing decl-specifiers
include\tinystr.h(112) : error C2143: syntax error : missing ';' before 'operator <op>'
include\tinystr.h(112) : error C2240: unexpected 'const int ' following formal list (only modifiers are allowed)
include\tinystr.h(113) : error C2501: 'bool' : missing decl-specifiers
include\tinystr.h(113) : error C2143: syntax error : missing ';' before 'operator <op>'
include\tinystr.h(113) : error C2240: unexpected 'const int ' following formal list (only modifiers are allowed)
include\tinystr.h(114) : error C2501: 'bool' : missing decl-specifiers
include\tinystr.h(114) : error C2143: syntax error : missing ';' before 'operator <op>'
include\tinystr.h(114) : error C2240: unexpected 'const int ' following formal list (only modifiers are allowed)
include\tinystr.h(117) : error C2501: 'bool' : missing decl-specifiers
include\tinystr.h(117) : error C2146: syntax error : missing ';' before identifier 'empty'
include\tinystr.h(118) : error C2240: unexpected 'const int ' following formal list (only modifiers are allowed)
c:\windows\temp\004780if(1) : error C2061: syntax error : identifier 'TiXmlOutStream'
Any help?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Well, I removed the program that was using it (thats what I thought). When I did a scan on stdafx almost 45 programs in the project showed up. So it is much bigger than what I thought. This is one of the legacy project.
Is there a way around to solve this problem? Just curious, what is in the stdafx that is causing the issue?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
If you have 45 separate projects, chances are they use their own stdafx.h. Or am I misunderstanding you?
stdafx.h is MSVC's way of doing precompiled headers.
In other words, if you normally #include "abc.h" and 100 other files, you can put them in stdafx.h and voila, they will be precompiled so you don't have to compile them every time.
So, you see why you need to take the CONTENTS of stdafx.h and put it into your project somewhere else.
Basically, create some project.h and put the contents of stdafx.h into it, then ensure everything that was including stdafx.h is now including project.h.
HTH
Ellers
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hmm. Sorry to be blunt but I think you need to read the MSVC++ documentation. Why are you using version v1.52? Is that suitable for a specific architecture or product or something?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Sorry it took too long. Well, after lot of research I found a way to use TinyXML along with VC1.52. I needed to do something which is not currently supported in VC1.52. (Converting 1.52 to 6 is too much of a work) so I created a dos vc6.0 app. Which is spawn from 1.52 and returns control back to legacy. It is working. Now here is my other issue.
I was now able to compile the program with out the C1010 issue, but I am getting
Hi,
I am using VC++ 1.52, based on the tutorial doc, I copied all the CPP and H files into my project. I added the cpp files to my project and when I compiled I got C1010 error.
Please help.
Thanks.
Turn off precompiled headers for that project.
Before doing any changes to the project, I was getting only 4 of the1010 error. I went to project and removed the stdafx from the precompiled headers and now I get arounf 399 errors; some of the errors are
include\tinystr.h(52) : error C2501: 'explicit' : missing decl-specifiers
include\tinystr.h(52) : error C2146: syntax error : missing ';' before identifier 'TiXmlString'
include\tinystr.h(63) : error C2501: 'explicit' : missing decl-specifiers
include\tinystr.h(63) : error C2146: syntax error : missing ';' before identifier 'TiXmlString'
/include\tinystr.h(111) : error C2501: 'bool' : missing decl-specifiers
include\tinystr.h(111) : error C2143: syntax error : missing ';' before 'operator <op>'
include\tinystr.h(111) : error C2240: unexpected 'const int ' following formal list (only modifiers are allowed)
include\tinystr.h(112) : error C2501: 'bool' : missing decl-specifiers
include\tinystr.h(112) : error C2143: syntax error : missing ';' before 'operator <op>'
include\tinystr.h(112) : error C2240: unexpected 'const int ' following formal list (only modifiers are allowed)
include\tinystr.h(113) : error C2501: 'bool' : missing decl-specifiers
include\tinystr.h(113) : error C2143: syntax error : missing ';' before 'operator <op>'
include\tinystr.h(113) : error C2240: unexpected 'const int ' following formal list (only modifiers are allowed)
include\tinystr.h(114) : error C2501: 'bool' : missing decl-specifiers
include\tinystr.h(114) : error C2143: syntax error : missing ';' before 'operator <op>'
include\tinystr.h(114) : error C2240: unexpected 'const int ' following formal list (only modifiers are allowed)
include\tinystr.h(117) : error C2501: 'bool' : missing decl-specifiers
include\tinystr.h(117) : error C2146: syntax error : missing ';' before identifier 'empty'
include\tinystr.h(118) : error C2240: unexpected 'const int ' following formal list (only modifiers are allowed)
c:\windows\temp\004780if(1) : error C2061: syntax error : identifier 'TiXmlOutStream'
Any help?
The includes that were contained in the stdafx.h - did you include them into your project?
Well, I removed the program that was using it (thats what I thought). When I did a scan on stdafx almost 45 programs in the project showed up. So it is much bigger than what I thought. This is one of the legacy project.
Is there a way around to solve this problem? Just curious, what is in the stdafx that is causing the issue?
If you have 45 separate projects, chances are they use their own stdafx.h. Or am I misunderstanding you?
stdafx.h is MSVC's way of doing precompiled headers.
In other words, if you normally #include "abc.h" and 100 other files, you can put them in stdafx.h and voila, they will be precompiled so you don't have to compile them every time.
So, you see why you need to take the CONTENTS of stdafx.h and put it into your project somewhere else.
Basically, create some project.h and put the contents of stdafx.h into it, then ensure everything that was including stdafx.h is now including project.h.
HTH
Ellers
One thing I found when I removed the stdafx.h, my debugging feature went over the limit. So I do not have the ability to debug the complete code.
Sorry to bother you with this. Is there any otherway, I would able to overcome this by setting something in the tinyxml.cpp?
Hmm. Sorry to be blunt but I think you need to read the MSVC++ documentation. Why are you using version v1.52? Is that suitable for a specific architecture or product or something?
Sorry it took too long. Well, after lot of research I found a way to use TinyXML along with VC1.52. I needed to do something which is not currently supported in VC1.52. (Converting 1.52 to 6 is too much of a work) so I created a dos vc6.0 app. Which is spawn from 1.52 and returns control back to legacy. It is working. Now here is my other issue.
I was now able to compile the program with out the C1010 issue, but I am getting
error C2065: 'TiXmlDocument' : undeclared identifier
I added tinyxml.h, tinystr.h and all the four .cpp as specified in the documentation.
Sorry to bug you. Please let me know what I am doing wrong?
Thanks.
Please ignore my previous message. It was my mistake, I didn't include tinyxml.h
My mistake sorry.