元素complexType名称属性

时间:2019-06-19 14:58:26

标签: c# wsdl asmx

如何在“ element”标签内为“ complexType”标签指定“ name”属性?举例来说。像这样:

<s:element name="recvMail">
    <s:complexType name="recvMail">
      <s:sequence>
        <s:element name="bMail"  type="tns:bMail"  minOccurs="0"/>
        <s:element name="bTrace" type="tns:bTrace" minOccurs="0"/>
        <s:element name="bBody"  type="tns:bBody"  minOccurs="0"/>
        <s:element name="bSign" type="s:string"   minOccurs="0"/>
      </s:sequence>
    </s:complexType>
  </s:element>

我正在使用ASP.NET .ASMX Web服务,尝试了许多属性。我已经在Google上冲浪了2天,但没有任何发现。任何帮助表示赞赏。非常感谢!

 [WebMethod(BufferResponse = false, CacheDuration = 60, EnableSession = false)]
 [SoapDocumentMethodAttribute("", RequestNamespace = "http://temp.ws.uri/", ResponseNamespace = "http://temp.ws.uri/", Use = SoapBindingUse.Literal,
   ParameterStyle = SoapParameterStyle.Wrapped)]
 [return: System.Xml.Serialization.XmlElementAttribute("bAnswer")]
 public bAnswer recvMail(bMail bMail, bTrace bTrace, bBody bBody, string bSign) { ... }

0 个答案:

没有答案