Click here to Skip to main content
15,901,035 members
Please Sign up or sign in to vote.
4.33/5 (3 votes)
See more:
I work with visual studio 2008 and get compiler errors for this line:[DllImport (HIGHGUI_LIBRARY)]
it does not recognize DllImport
Please, I need your help. Thank you.
Updated 20-May-10 20:05pm

You probably need to add a using at the top of your code:

using System.Runtime.InteropServices;

For more info on the DllImport attribute, you can check out this link:[^]

Bonne chance
Share this answer

While I hope your error is solved as this is tagged under C# may I suggest looking at EMGU ([^]). It's a C# wrapper for OpenCV that thankfully is free and allows quick use of OpenCV functionality within a C# environment.

It will hopefully make your programming quicker and easier as you will not have to import the libraries and can simply reference the relevant .dll.

As the EMGU website is having difficulties at the moment you can acquire the source at[^] please be aware that there are x86 and x64 versions available.

Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900