public OpcionalTipoResponse GetTiposOpcional(FEAuthRequest feAuthRequest) { AfipWrapperServiceClient client = new AfipWrapperServiceClient(); ClientCredentialHelper.SetCredentials(client.ClientCredentials); try { var t = client.GetTiposOpcional(feAuthRequest); client.Close(); return(t); } catch { if (client.State != System.ServiceModel.CommunicationState.Closed) { client.Abort(); } throw; } }
public ClsFEXAuthRequest ObtenerTicketFex() { AfipWrapperServiceClient client = new AfipWrapperServiceClient(); ClientCredentialHelper.SetCredentials(client.ClientCredentials); try { var t = client.ObtenerTicketFex(); client.Close(); return(t); } catch { if (client.State != System.ServiceModel.CommunicationState.Closed) { client.Abort(); } throw; } return(null); }