using System::Drawing namespace in managed C++ class library
I am moving a few functions from a Managed C++ Winforms app to a class library so that I can call them in a new C# app I'm writing. However one of the functions returns a System::Drawing::Bitmap^ and uses the System::Drawing::Color class which is causing an error saying that System does not contain a namespace called Drawing ...
Obviously it does, but I'm guessing that since a class library does not intrinsi开发者_开发问答cally have a graphical element to it like a winform does that there may be an extra step for accessing the functionality?
What do i need to add/link-to?
Thank you in advance.
Tony.
You probably need to add a reference to System.Drawing.dll
. Right-click your project and choose "Add Reference", it should be there somewhere.
精彩评论