-
Someone must know
I am running a program in MSVC and it won't run because it gets a ton of errors from the include files. I have no idea why, maybe the code itself. But anyways, I was wondering if maybe I am using the wrong project type.
I have gotten examples that come with the compiler to work.
I am using Directx9.0 and the code is made for 8.0. I can send you the code that doesn't work or post some errors if you feel that will help.
Any suggestions are welcomed.
-
c:\dxsdk\samples\c++\common\include\d3dapp.h(50) : error C2146: syntax error : missing ';' before identifier 'm_d3dEnumeration'
c:\dxsdk\samples\c++\common\include\d3dapp.h(50) : error C2501: 'CD3DEnumeration' : missing storage-class or type specifiers
c:\dxsdk\samples\c++\common\include\d3dapp.h(50) : error C2501: 'm_d3dEnumeration' : missing storage-class or type specifiers
c:\dxsdk\samples\c++\common\include\d3dapp.h(51) : error C2146: syntax error : missing ';' before identifier 'm_d3dSettings'
c:\dxsdk\samples\c++\common\include\d3dapp.h(51) : error C2501: 'CD3DSettings' : missing storage-class or type specifiers
c:\dxsdk\samples\c++\common\include\d3dapp.h(51) : error C2501: 'm_d3dSettings' : missing storage-class or type specifiers
c:\dxsdk\samples\c++\common\include\d3dapp.h(71) : error C2061: syntax error : identifier 'D3DCAPS9'
c:\dxsdk\samples\c++\common\include\d3dapp.h(94) : error C2146: syntax error : missing ';' before identifier 'm_pD3D'
c:\dxsdk\samples\c++\common\include\d3dapp.h(94) : error C2501: 'LPDIRECT3D9' : missing storage-class or type specifiers
c:\dxsdk\samples\c++\common\include\d3dapp.h(94) : error C2501: 'm_pD3D' : missing storage-class or type specifiers
I get 102 of these, and it says it stops at 100 so I'm guessing theres a ton more, which is why I think its something to do with the workspace or the code itself.
-
may be something as simple as a missing }, but we'll never know without the code immediately preceding the line referred to in the first error message and the line itself. May even need more than that, but that's the next step: matching pertinent code to the first error message.
-
>>missing ';' before identifier 'm_d3dEnumeration'
looks more like a missing semicolon :)
-
Syntax errors, you're missing the semicolon somewhere.
-
The program I am trying to run is called basic. Those errors are from d3dapp.
-
Actually, here is my project, not sure if the workspace includes the files I am trying to compile though.
-
-
Actually salem this is example code from a book I bought written for the compiler, so I want it to work so I can use my book and din't waste money on it.
-
Looks like you aren't linking to the correct libraries and/or including the correct headers. Check and make sure.
-
I made sure I followed the instructions in the book exactly.
-
Someone has to have an answer, does it work for you when you compile?
-
looks like it doesn't know what CD3DEnumeration is.
Never mind the semicolon, just figure out where CD3DEnumeration lives and make sure its included
-
Why don't you zip up your project and attach it. Then we can take a closer look.
-
I did zip it up, and I did make sure to include where it lives, it says theres an error with it, so it must be finding it.