我有一个带有 Service.svc 文件的网站,我使用 Add New Item -> AJAX-enabled WCF Service 创建了它,几周以来,一切正常。今天,我导入了 EPplus.dll 来生成一些 excel 文件。当我尝试编译时出现此错误
Error 1 Reference.svcmap:
Failed to generate code for the service reference 'QUAY.Tractebel.COP.Servicos'.
Cannot import wsdl:portType Detail: An exception was thrown while running a WSDL import extension:
System.ServiceModel.Description.DataContractSerializerMessageContractImporter
Error: Type 'OfficeOpenXml.ExcelRangeBase' is a recursive collection data contract which is not supported.
Consider modifying the definition of collection 'OfficeOpenXml.ExcelRangeBase' to remove references to itself.
XPath to Error Source: //wsdl:definitions[@targetNamespace='']/wsdl:portType[@name='Servicos'] App_WebReferences/QUAY/Tractebel/COP/Servicos/
我不知道如何解决它,有人可以帮助我吗?