



Hey there,
yesterday I reinstalled everything on my computer, including the 6.8 version of RackAFX and Visual Studio 2017 Community. For some reason, I get error messages when opening older projects that used to work. The error consists of Visual Studio saying that certain words are not defined, like "NULL" or UINT. I tried to solve the issue by putting #include <cmath> at the top (since NULL is part of that) and I changed every UINT to unsigned long manually, but after that I get different error messages from the functions that include those terms.
Any idea about how to fix this or what the problem is?
Thanks!
I will look into this. It seems that something in VS2017 changed since I added support for it, via a Service Pack or OS update. UINT and NULL should be defined with <windows.h> which is in pluginconstants.h. What OS are you using?
I should have a new RackAFX release within a week or so and I will address this. For now, the easiest thing is to use VS2015 Community which is also free.
- Will
I've done some debug work and found the reason that this is happening; it appears to be a bug in Visual Studio 2017 regarding updating older projects to the newer platform, or creating a new project in RackAFX. It has to do with the fact that VS2015 and VS2017 include new project settings to target specific Operating Systems - this doesn't matter for our DLLs, but it does matter when the compiler tries to locate the Windows SDK files needed. When opening an older project in VS2017, you get a message to upgrade your project to the latest settings, and this includes the OS Target. The message box tells you that it is upgrading to a 10.0.xxxxx version:
However, if you click OK and then check the settings, you will see that they are not changed in your Solution Properties:
This is causing your problem because you don't have the Win8.1 SDK installed on you computer.
The way to fix this is easy but will need to be done for each project, old or new. After upgrading or creating a new project, right click on the Solution and choose "Retarget Projects" then select the 10.0.xxxxx version from the dialog. After executing this, the target OS will be properly changed.Â
This is also a problem for new RackAFX projects, which contain NO information on a target OS. It turns out that the VS2017 project default is Win8.1, even if you are on Win10 and even if you don't have the SDK installed. Also, installing the Win8.1 SDK from Microsoft won't work either - it does not include the library files (all the windows .h files) you need (why, I don't know...)
This is also something that is a pain for me, because I can't simply insert the 10.0.xxxxx value into the project file, as it might change at any time they do a new OS update, or a new VS2017 update, causing the problem to happen all over again. I will report this to Microsoft and hopefully they will fix it in a future update. But at least you can now use VS2017 without all the errors by following that step.
- Will
NOTE: if you have VS2015 installed and you are compiling properly, then you may be self-fixed. Check to see if you have the Windows 8.1SDK installed. It will be in:
C:\Program Files (x86)\Windows Kits\8.1
Inside of that, you should have \Include\shared folder which contains the .h files that #include <windows.h> requires. Inside that folder you will find minwindef.h which defines the UINT and other Win-specific defines. If you have this folder, then you should be able to properly compile with VS2017 without errors.Â
Will
Most Users Ever Online: 152
Currently Online:
6 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Chaes: 56
Skyler: 48
StevieD: 46
Derek: 46
Frodson: 45
Peter: 43
TheSmile: 43
Nickolai: 43
clau_ste: 39
jeanlecode: 37
Member Stats:
Guest Posters: 1
Members: 775
Moderators: 1
Admins: 6
Forum Stats:
Groups: 13
Forums: 42
Topics: 846
Posts: 3353
Moderators: W Pirkle: 690