المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : WIA initialize object problem



C# Programming
11-05-2009, 07:32 PM
Hey,

I got a project to make an video application (that I can see myself on windows form).

The problem is that I dont know how to do that kind of things, so I searched the net and found the WIA COM and thinking of using it.

I found that article: WIA Scripting and .NET (http://www.codeproject.com/KB/dotnet/wiascriptingdotnet.aspx)[^ (http://www.codeproject.com/KB/dotnet/wiascriptingdotnet.aspx)]

But for some reason my computter says that the COM "WIALib" not exists... so I continued search and found that:
http://www.codeguru.com/forum/showthread.php?t=439027[^ (http://www.codeguru.com/forum/showthread.php?t=439027)]

But for some reason, the line
CommonDialogClass class1 = new CommonDialogClass();

Gives me an problem
Error 2 Interop type 'WIA.CommonDialogClass' cannot be embedded. Use the applicable interface instead. C:\Users\Yahav\Documents\Visual Studio 2010\Projects\ControlCamera\ControlCamera\Form1.cs 69 40 ControlCamera


and the same for that:
DeviceManager manager = new DeviceManagerClass();

Someone can explain me why?

Thank you very very moch! Yahav.

Gindi Bar Yahav - Web & Software developer.