Visual Studio Reporting many errors after Changing the Reference Files to 2022 version
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hey Forum, (and maybe Mr. @naveen.kumar.t in perticular as I've seen many great solutions from him),
I have created a Revit add-in using the RevitAPI.dll and RevitAPIUI.dll files as references from the Revit 2020 folder. Working well for Revit up to 2021, but not for Revit 2022. I understand there have been some API changes in Revit 2022. So in order to update my add-in for Revit 2022, i removed the references, and added the version 2022 .dll files. I got a few errors in my code because of the API changes, but I was perfectly able to fix those.
When I build my solution, this is where the trouble starts: I get errors, many errors, pretty much all of them saying:
CS0234 The type or namespace name 'Revit' does not exist in the namespace 'Autodesk' (are you missing an assembly reference?)
this error shows 594 times, with different things missing, but all of them being types or namespaces that are absolutely available. When I double click the error, the class it is in opens, and the error disappears. I can do this for all of them, but building the solution still fails, and when I save and close the class-files in VS, then build the solution again, all the errors come back.
There's probably a single setting or line that I need to change, but I cannot figure out what that is. Please help.
Thank you,