Jump to content
The simFlight Network Forums

FSUIPC.h (MFC version) in VC++.NET 2003


Recommended Posts

Hi Pete,

I've already written one program succesfully a couple years ago using your SDK and VC++6. I've upgraded to VC++.NET 2003 and am now having trouble getting the FSUIPC files to compile. I have got the error list down to 21 items, most seem to be hung up on the DWORD data type and class definitions in FSUIPC.h. I've searched MSDN and can't find any reference to DWORD in the documentation. The DWORD data type worked fine in VC++6. Have you any tips or tricks to get past this issue?

Additionally, I'm using a Windows Forms project. I tried starting a MFC Application and the files compiled correctly without errors.

I've searched this forum for similar issues and found nearly nothing in reference to VC++.NET 2003.

Thanks for your help and your product.

Justin

Link to comment
Share on other sites

I've already written one program succesfully a couple years ago using your SDK and VC++6. I've upgraded to VC++.NET 2003 and am now having trouble getting the FSUIPC files to compile. I have got the error list down to 21 items, most seem to be hung up on the DWORD data type and class definitions in FSUIPC.h.

Two things here:

1. I use VC .NET 2003 and have been doing now since it became available. Everything compiles fine. I suspect your trouble may be to do with the fact that everything I provide is C, not C++ -- maybe you need to use C or put some parentheses around the H file to tell the C++ compiler that it is C not C++?

2. There are no classes defined in FSUIPC.H because C does not support Classes. ;-)

I've searched MSDN and can't find any reference to DWORD in the documentation. The DWORD data type worked fine in VC++6. Have you any tips or tricks to get past this issue?

DWORD is still a standard Windows data type -- it sounds like your Windows headers are corrupted? Very very many of the Windows API calls are defined with DWORD parameters or results -- even basic things like GetLastError, for example.

DWORD is simply defined as an unsigned long or unsigned int. Of course, when we eventually get to 64-bit compilation all this will beed a good overhaul.

Regards

Pete

Link to comment
Share on other sites

Thank you for your quick response.

I'm not certain of how I am supposed to put parenthesis around the H file. I've tried a few different combinations and it gives me a file not found error. This procedure forces the compiler to view the H file as a C file rather than C++?

I'm continuing to do research on it. I may have to ditch the Windows Forms project and create it as a MFC Dialog Application where the FSUIPC files compile correctly through VC++.NET 2003.

Justin

Link to comment
Share on other sites

I may have to ditch the Windows Forms project and create it as a MFC Dialog Application where the FSUIPC files compile correctly through VC++.NET 2003.

Did you simply try defining (typedef'ing) DWORD and an unsigned long?

Seems odd that MS provide facilities so self-inconsistent. I'm afraid I don't know "Windows Forms" at all (in fact I've never heard of them), and I've avoided MFC altogether. I like my code to be completely under my control and as compact and efficient as possible, and I can only ensure that by using plain C, which ASM in places where I need even greater control.

Maybe some one else here uses and understands "Windows Forms" and can help. Sorry I cannot.

Regards,

Pete

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.