Hello,
I want to work with the HighlightOverrule class. According to the online documentation, this class is derived from the following hierarchy: Autodesk.AutoCAD.DatabaseServices.HighlightOverrule.
However, when I try to implement it in my project, the class is not found. The issue is that I am using recent versions of the .NET framework. My question is, does this class still exist?
Thank you.
Solved! Go to Solution.
Solved by ActivistInvestor. Go to Solution.
You might want to try clarify what you asked:
What does mean "class is not found"? Do you simply look through the Object Browser for the Autodesk.AutoCAD.DatabaseServices namespace (I am SURE you have Acadbmgd.dll referenced in your project)? If you do not see Autodesk.AutoCAD.DatabaseServices in the Object Browser window, then you ARE not doing AutoCAD .NET programming project. Or, you might simply missing "using Autodesk.AutoCAD.DatabaseServices;" in your *.cs/*.vb code file.
Rather than saying "...recent version of .NET framework...", why not say EXACTLY WHICH VERSION of .NET Framework? If you are doing Acad2024 or older version of AutoCAD, .NET framework version would have nothing to do with HighlightOverrule class being found or not: it is in the AcadDbMgd.dll.
Norman Yuan
HighlightOverrule exists in every version of AutoCAD.
It requires a reference to AcDbMdg.dll.
The version of the framework you're using has nothing to do with it, other than that you must be using a version that's compatible with the version of AutoCAD you're targeting.
I have the AcDbMdg.dll reference loaded in my project, but even with that, HighlightOverrule is not detected by my Visual Studio.
Here is a part of the code where I have the problem:
These are the DLLs loaded in my project:
What about "...recent version of .NET framework" you mentioned? Are you sure you created CORRECT(!) .NET Framework class library project (for Acad2024 or older), or .NET 8 class library project for Acad2025?
Norman Yuan
You are having the problem because the containing namespace has the same name as the class. Change the name of the namespace from HighlightOverrule to something else.
Can't find what you're looking for? Ask the community or share your knowledge.