无法生成临时类(结果= 1).错误CS0030: [英] Unable to generate a temporary class (result=1). error CS0030:

查看:84
本文介绍了无法生成临时类(结果= 1).错误CS0030:的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用https://www.sandbox.paypal进行贝宝快速结帐.com/wsdl/PayPalSvc.wsdl . 当我打电话使用

I am trying to paypal express checkout i used https://www.sandbox.paypal.com/wsdl/PayPalSvc.wsdl. when i call use

PayPalAPIAASoapBinding paypal = new PayPalAPIAASoapBinding(); 

我遇到错误

无法生成临时类(结果= 1).错误CS0030: 无法转换类型 'exprtesscheckoutdemo.com.paypal.sandbox.TupleType []'到 "paypal.sandbox.TupleType"错误CS0029:无法隐式转换 在"

Unable to generate a temporary class (result=1). error CS0030: Cannot convert type 'exprtesscheckoutdemo.com.paypal.sandbox.TupleType[]' to 'paypal.sandbox.TupleType' error CS0029: Cannot implicitly convert type 'paypal.sandbox.TupleType' to

如何克服这个问题

推荐答案

在更新到版本119时,请自己解决这个问题.在生成的Web服务文件中,查找[][],并将所有出现的内容替换为[].坏人似乎是PaymentDetailsType中的merchantDataField.

Just hit this myself when updating to version 119. In your generated Web service file, do a find for [][] and replace all occurrences with []. The bad guy seems to be the merchantDataField in the PaymentDetailsType.

这似乎是Microsoft WSDL工具中的错误与具有将maxOccurs属性设置为无界的嵌套节点"的服务进行交互时;在与FedEx SOAP API交互时,我也曾遇到过它.

It seems to be a bug in the Microsoft WSDL tools when interacting with services that have "nested nodes with the maxOccurs attribute set to unbounded"; I've encountered it before when interacting with FedEx SOAP APIs as well.

这篇关于无法生成临时类(结果= 1).错误CS0030:的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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