コード例 #1
0
        public void EjecutarCorrida(EjecutarCorridaSubidaArchivo corrida)
        {
            CorridaSubidaArchivoDto    dto    = null;
            SubidaArchivoServiceClient client = new SubidaArchivoServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                client.EjecutarCorrida(corrida);
                client.Close();
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }
            }
        }
コード例 #2
0
        public void EjecutarCorrida(long corridaId)
        {
            ProcesoCorridaServiceClient client = new ProcesoCorridaServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                client.EjecutarCorrida(corridaId);
                client.Close();
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }
        }
コード例 #3
0
        public List <TipoContratoDto> ObtenerTiposContrato()
        {
            FacturaElectronica.Ui.Win.Administrador.ServiceReferenceComprobanteService.ComprobanteServiceClient client = new FacturaElectronica.Ui.Win.Administrador.ServiceReferenceComprobanteService.ComprobanteServiceClient();
            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                var t = client.ObtenerTiposContrato();
                client.Close();
                return(t);
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }
        }
コード例 #4
0
        public FECompConsultaResponse CompConsultar(FEAuthRequest feAuthRequest, FECompConsultaReq feCompConsultaReq)
        {
            AfipWrapperServiceClient client = new AfipWrapperServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                var t = client.CompConsultar(feAuthRequest, feCompConsultaReq);
                client.Close();
                return(t);
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }
        }
コード例 #5
0
        public FETributoResponse GetTiposTributos(FEAuthRequest feAuthRequest)
        {
            AfipWrapperServiceClient client = new AfipWrapperServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                var t = client.GetTiposTributos(feAuthRequest);
                client.Close();
                return(t);
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }
        }
コード例 #6
0
        public FEXResponse_Umed GetUnidadesDeMedida(ClsFEXAuthRequest fexAuthRequest)
        {
            AfipWrapperServiceClient client = new AfipWrapperServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                var t = client.GetUnidadesDeMedida(fexAuthRequest);
                client.Close();
                return(t);
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }
        }
コード例 #7
0
        public FEXResponse_Cbte_Tipo GetTiposComprobantes(ClsFEXAuthRequest fexAuthRequest)
        {
            AfipWrapperServiceClient client = new AfipWrapperServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                var t = client.GetTiposComprobantes(fexAuthRequest);
                client.Close();
                return(t);
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }
        }
コード例 #8
0
        public FEXResponse_Ctz GetFexCotizacion(ClsFEXAuthRequest fexAuthRequest, string monId)
        {
            AfipWrapperServiceClient client = new AfipWrapperServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                var t = client.GetFexCotizacion(fexAuthRequest, monId);
                client.Close();
                return(t);
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }
        }
コード例 #9
0
        public FEXResponse_CheckPermiso CheckPermiso(ClsFEXAuthRequest fexAuthRequest, string idPermiso, int destMerc)
        {
            AfipWrapperServiceClient client = new AfipWrapperServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                var t = client.CheckPermiso(fexAuthRequest, idPermiso, destMerc);
                client.Close();
                return(t);
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }
        }
コード例 #10
0
        public FEXResponseLast_CMP GetUltimoComprobanteAutorizado(ClsFEX_LastCMP fexLastCmp)
        {
            AfipWrapperServiceClient client = new AfipWrapperServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                var t = client.GetUltimoComprobanteAutorizado(fexLastCmp);
                client.Close();
                return(t);
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }
        }
コード例 #11
0
        public FEAuthRequest ObtenerTicket()
        {
            AfipWrapperServiceClient client = new AfipWrapperServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                var t = client.ObtenerTicket();
                client.Close();
                return(t);
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }
        }
コード例 #12
0
        public FEXResponseAuthorize AutorizarComprobanteExportacion(ClsFEXAuthRequest fexAuthRequest, ClsFEXRequest fexRequest)
        {
            AfipWrapperServiceClient client = new AfipWrapperServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                var t = client.AutorizarComprobanteExportacion(fexAuthRequest, fexRequest);
                client.Close();
                return(t);
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }
        }
コード例 #13
0
        public FERecuperaLastCbteResponse CompUltimoAutorizado(FEAuthRequest feAuthRequest, int ptoVta, int cbteTipo)
        {
            AfipWrapperServiceClient client = new AfipWrapperServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                var t = client.CompUltimoAutorizado(feAuthRequest, ptoVta, cbteTipo);
                client.Close();
                return(t);
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }
        }
コード例 #14
0
        public CorridaSubidaArchivoDto CrearNuevaCorrida()
        {
            CorridaSubidaArchivoDto    dto    = null;
            SubidaArchivoServiceClient client = new SubidaArchivoServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                dto = client.CrearNuevaCorrida();
                client.Close();
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }

            return(dto);
        }
コード例 #15
0
        public List <WebServiceAfipDto> ObtenerWebServicesAfip()
        {
            List <WebServiceAfipDto> dto    = new List <WebServiceAfipDto>();
            MaestrosServiceClient    client = new MaestrosServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                dto = client.ObtenerWebServicesAfip();
                client.Close();
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }

            return(dto);
        }
コード例 #16
0
        public List <LogCorridaDto> ConsultarLog(LogSearch search)
        {
            List <LogCorridaDto>        dto    = null;
            ProcesoCorridaServiceClient client = new ProcesoCorridaServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                dto = client.ConsultarLog(search);
                client.Close();
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }

            return(dto);
        }
コード例 #17
0
        public List <CorridaAutorizacionDto> ObtenerCorridas(CorridaSearch search)
        {
            List <CorridaAutorizacionDto> dto    = null;
            ProcesoCorridaServiceClient   client = new ProcesoCorridaServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                dto = client.ObtenerCorridas(search);
                client.Close();
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }

            return(dto);
        }
コード例 #18
0
        public CorridaAutorizacionDto CrearNuevaCorrida(string nombreDeArchivo)
        {
            CorridaAutorizacionDto      dto    = null;
            ProcesoCorridaServiceClient client = new ProcesoCorridaServiceClient();

            ClientCredentialHelper.SetCredentials(client.ClientCredentials);
            try
            {
                dto = client.CrearNuevaCorrida(nombreDeArchivo);
                client.Close();
            }
            catch
            {
                if (client.State != System.ServiceModel.CommunicationState.Closed)
                {
                    client.Abort();
                }

                throw;
            }

            return(dto);
        }