当前位置: 代码迷 >> Web Service >> 邪门了,简单的例子都编译不了:ServiceDescriptionImporter,该怎么处理
  详细解决方案

邪门了,简单的例子都编译不了:ServiceDescriptionImporter,该怎么处理

热度:307   发布时间:2012-02-12 17:16:33.0
邪门了,简单的例子都编译不了:ServiceDescriptionImporter
麻烦用VS2010 .net4.0的帮我试试,用MSND上的例子都找不到ServiceDescriptionImporter

具体的步骤如下:

1. File | New | Project | Console Applicaiton
2. 浏览器,打开: http://msdn.microsoft.com/zh-cn/library/system.web.services.description.servicedescriptionimporter%28v=VS.100%29.aspx
3. COPY下面C#的实例
4. paste到VS2010的program.cs里
5. Add reference : System.web.Service
6. Build

Error 1 The type or namespace name 'ServiceDescriptionImporter' could not be found (are you missing a using directive or an assembly reference?) C:\temp\ConsoleApplication2\ConsoleApplication2\Program.cs 22 9 ConsoleApplication2

我知道有人也遇到这类问题,但没解决。



------解决方案--------------------
using System.Web.Services.Description;

只能把分给我了:)