Thiago Lima RCKY
Membros-
Total de ítens
1 -
Registro em
-
Última visita
Últimos Visitantes
O bloco dos últimos visitantes está desativado e não está sendo visualizado por outros usuários.
Thiago Lima RCKY's Achievements
-
Rejeição: Falha No Schema Xml Do Lote De Nfe
Thiago Lima RCKY replied to eduardoribeiro's tópico in ACBrNFe
Boa tarde Caros, tive esse mesmo problema no Sefaz do PR e MT para NF-e 4.00: <cStat>215</cStat> <xMotivo>Falha no schema XML org.xml.sax.SAXParseException; lineNumber: 1; columnNumber: 6; cvc-elt.1: Cannot find the declaration of element 'NFe'. No meu caso consegui resolver criando a classe de WebService na mão. Programo em C# e quando importava a classe pela ferramente do VisualStudio de alguma forma a classe importado corrompia o envio da NFeAutorizacao4 Segue anexo minha classe C# funcionando: Fonte de Estudo do Projeto: https://github.com/ZeusAutomacao/DFe.NET using System; using System.Security.Cryptography.X509Certificates; using System.Web.Services; using System.Web.Services.Description; using System.Web.Services.Protocols; using System.Xml; using System.Xml.Serialization; namespace Rcky.Nfe.WebServices.Versao400.NFe.PR { [WebServiceBinding(Name = "NFeAutorizacao4Service", Namespace = "http://www.portalfiscal.inf.br/nfe/wsdl/NFeAutorizacao4")] public class NFeAutorizacao4 : SoapHttpClientProtocol { public NFeAutorizacao4(string url, X509Certificate certificado, int timeOut) { SoapVersion = SoapProtocolVersion.Soap12; Url = url; //Timeout = timeOut; /* Vou deixar o tempo Default da classe de 100.000 milesegundos */ ClientCertificates.Add(certificado); } //[Obsolete("Não utilizar na nfe 4.0")] //public nfeCabecMsg nfeCabecMsg { get; set; } [SoapDocumentMethod("http://www.portalfiscal.inf.br/nfe/wsdl/NFeAutorizacao4/nfeAutorizacaoLote", Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Bare)] [WebMethod(MessageName = "nfeAutorizacaoLote")] [return: XmlElement("nfeResultMsg", Namespace = "http://www.portalfiscal.inf.br/nfe/wsdl/NFeAutorizacao4")] public XmlNode Execute([XmlElement(Namespace = "http://www.portalfiscal.inf.br/nfe/wsdl/NFeAutorizacao4")] XmlNode nfeDadosMsg) { var results = Invoke("nfeAutorizacaoLote", new object[] { nfeDadosMsg }); return ((XmlNode)(results[0])); } [SoapDocumentMethod("http://www.portalfiscal.inf.br/nfe/wsdl/NFeAutorizacao4/nfeAutorizacaoLoteZIP", Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Bare)] [WebMethod(MessageName = "nfeAutorizacaoLoteZIP")] [return: XmlElement("nfeResultMsg", Namespace = "http://www.portalfiscal.inf.br/nfe/wsdl/NFeAutorizacao4")] public XmlNode ExecuteZip([XmlElement(Namespace = "http://www.portalfiscal.inf.br/nfe/wsdl/NFeAutorizacao4")] string nfeDadosMsgZip) { var results = Invoke("nfeAutorizacaoLoteZIP", new object[] { nfeDadosMsgZip }); return ((XmlNode)(results[0])); } } }