找不到类型或命名空间名称“Document”(您是否缺少using指令或程序集引用?) [英] The type or namespace name 'Document' could not be found (are you missing a using directive or an assembly reference?)

查看:628
本文介绍了找不到类型或命名空间名称“Document”(您是否缺少using指令或程序集引用?)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

I was created windows application in which MODI.dll & axmodi.dll were used for Image to Text (OCR processing) (Window-application- c#). It Worked fine without throwing an ERROR.

Now like to implement on ASP.net (C#) as the same. But it throw error even added needed Reference. "The type or namespace name 'Document' could not be found (are you missing a using directive or an assembly reference?)" This is the error i am getting.

推荐答案

您需要在页面顶部添加正确的使用。右键单击visual studio中的Document,上下文菜单中应该有一个Resolve选项,可以为您提供使用。
You need to add the correct "using" at the top of the page. Right-click "Document" in visual studio and there should be a "Resolve" option in the context menu that will offer you a possible "using".


解决方案1的一个补充,一次你已经编写了代码,例如



An addition to Solution 1, once you've written the code such as

using Namespace;





它不包括项目中的程序集,它只允许您在源文件中使用该命名空间内的类。您必须手动将程序集包含到项目中。您需要做的是,右键单击引用并选择添加引用。在显示的窗口内,选择包含 Document 类的命名空间(程序集)。然后这个错误就会消失。



it doesn't include the assembly in your project it just allows you to use the classes inside that namespace in your source file. You have to manually include the assembly to the project. What you need to do is, to right click on the References and select Add Reference. Inside the window that shows up, select the namespace (assembly) that contains the Document class. Then this error would go away.


这篇关于找不到类型或命名空间名称“Document”(您是否缺少using指令或程序集引用?)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆