com interop - Take a picture from Integrated Laptop Camera using C# -
i trying write 1 portion of huge c# program allows me capture 1 picture integrate camera in laptop. have done research , notice there 2 ways via wia , directshow. trying easier 1 : wia. working on windows 7 32 bit machine running vs 2010 .net 4.0 . trying run following example found on web, want , experienced several errors regards it.
http://www.c-sharpcorner.com/uploadfile/yougerthen/610262008064756am/6.aspx
i have added necessary reference
using system.windows.forms; using microsoft.win32; using wia;
majority of errors following : interop type 'wia.commondialogclass' cannot embedded. use applicable interface instead. interop type 'wia.commandid' cannot embedded. use applicable interface instead.
any provided appericiated.
try this:
wia.commondialog wiadiag = new wia.commondialog();
creating com interfaces new operator allowed. need prefix namespace name because commondialog ambiguous winforms commondialog class.
Comments
Post a Comment