Saturday, June 10, 2006 8:50 AM
Hi all, I'm running into a huge problem and am desperate in trying to find a solution.
Upgraded to the Beta 2 SDK (Uninstalled all the Beta 1 stuff first) and am trying to recompile my code. I get the following error:
1>C:\Program Files\Microsoft SDKs\Windows\v1.0\Include\unknwn.idl(108) : error MIDL2025 : syntax error : expecting ] or , near "annotation"
1>C:\Program Files\Microsoft SDKs\Windows\v1.0\Include\unknwn.idl(108) : error MIDL2026 : cannot recover from earlier syntax errors; aborting compilation
I followed the directions in the SDK readme to setup the include and library paths and have them moved up to the top of their respective lists in the exact same order as in the readme file.
Does anyone know how to resolve this issue?
Unfortunately, I'm dead in the water until I can get past this! Any help would be greatly appreciated!
PS. For reference, double clicking on the error shows the following at that location (the carrot points to the line where the error is supposedly occuring):
[in] REFIID riid,
> [out, iid_is(riid), annotation("__RPC__deref_out")] void **ppvObject);
Saturday, June 10, 2006 4:39 PMSee my reply to your post in the other thread: http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=466558&SiteID=1&mode=1
Saturday, June 10, 2006 6:39 PM
Thanks, added a reply to that post.
I need to find a way to get to the bottom of this issue... I'm working on a commercial project targetted at XP and Vista (figure most users will still be using XP initially) that is currently dead in the water as I can't get critical DLLs to compile in XP at the moment :(
Sunday, June 11, 2006 12:51 AM
1. Uninstalled Windows SDK, .NET 2.0, WinFX runtime, Orcas and reinstalled. No luck.
2. Uninstalled the above and reinstalled, but instead of using the Windows SDK img file I did it from the Setup.exe to re-download all the stuff online... No luck.
3. Created a new project. Created new idl file. Tried to compile. No luck.
What can cause this problem?
Include and library files are all there. Paths in VS2005 have been updated to point to the install locations. Project settings look ok...
Is there anything else that can cause this to happen?
Perhaps, knowing what could cause this file to not compile could help in troubleshooting the problem here.
Note 1: this is in XP SP2 with all updates.
Note 2: all this stuff compiled with the Beta 1 SDK.
Sunday, June 11, 2006 1:11 AM
If I remove the Windows SDK items from (4 includes, 2 libraries) from tools-options the idl files compile... ofcourse this is probably a bad thing since it's not using the "latest and greatest" from the new Windows SDK.
This seems to point to a problem with the Windows SDK and not the VS install.
No idea what's causing this... I think the ball's in your court now Microsoft.
Tuesday, June 13, 2006 7:28 PMSee http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=466558&SiteID=1&mode=1 for an update and possible solution for this issue.
Sunday, June 18, 2006 11:18 PM
Thanks Dave, just tried out your solution and posted in the other thread that it works perfectly.
Friday, November 09, 2007 7:14 PM
I've run into this problem as well. The posting in the other thread didn't help me... I've found that if you do have the new SDK directories added correctly to the environment, but you are still getting this error, then you need to make sure that during the SDK install, you included the Development Utilities/Tools for .NET/Win32. This has a new MIDL compiler, and if it is not installed, you'd still see the errors. I did a lean and mean install that was a little too lean.