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

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

问题描述

为什么我在c#中获取错误

why iam getting the error in c#

推荐答案

确保引用您想要使用的程序集。阅读命名空间和完整类型名称,并确保正确命名:

http ://msdn.microsoft.com/en-us/library/wkze6zky.aspx [ ^ ],

http://msdn.microsoft.com/en-us/library/ms973231.aspx [ ^ ]。



学习阅读错误信息并理解它们。阅读.NET和语言手册,以确保您自己了解术语和概念(至少)。



-SA
Make sure you reference the assembly you wanted to use. Read about namespace and full type names and make sure you name things correctly:
http://msdn.microsoft.com/en-us/library/wkze6zky.aspx[^],
http://msdn.microsoft.com/en-us/library/ms973231.aspx[^].

Learn to read error messages and understand them. Read a .NET and language manual to make sure you know the terminology and the notions themselves (at the very least).

—SA


如果您的代码引用了项目中未包含的类,则会发生此错误。您需要为我们发布代码,以便为您提供更好的主意。编译器不知道什么服务。无论如何。
This error happens when you have code that is referencing classes that have not been included in your project. You would need to post the code for us to give you a better idea. The compiler does not know what Service. whatever is.


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

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