public static List <CLNT> ObtenerTodosLosClientes() { List <CLNT> _tempClients = new List <CLNT>(); Database1DataSet.ObtenerTodoLosClientesDataTable DT = new Database1DataSet.ObtenerTodoLosClientesDataTable(); Database1DataSetTableAdapters.ObtenerTodoLosClientesTableAdapter TA = new Database1DataSetTableAdapters.ObtenerTodoLosClientesTableAdapter(); TA.Fill(DT); if (DT.Rows.Count > 0) { foreach (System.Data.DataRow DR in DT.Rows) { _tempClients.Add(new CLNT( int.Parse(DR["Id"].ToString()), DR["Nombre"].ToString(), DR["Apellido"].ToString(), DR["Telefono"].ToString(), DR["NumeroDocumento"].ToString(), DR["Domicilio"].ToString(), DR["CUIT"].ToString(), DR["CUIL"].ToString() )); } } return(_tempClients); }
public static List<CLNT> ObtenerTodosLosClientes() { List<CLNT> _tempClients = new List<CLNT>(); Database1DataSet.ObtenerTodoLosClientesDataTable DT = new Database1DataSet.ObtenerTodoLosClientesDataTable(); Database1DataSetTableAdapters.ObtenerTodoLosClientesTableAdapter TA = new Database1DataSetTableAdapters.ObtenerTodoLosClientesTableAdapter(); TA.Fill(DT); if (DT.Rows.Count > 0) { foreach (System.Data.DataRow DR in DT.Rows) { _tempClients.Add(new CLNT( int.Parse(DR["Id"].ToString()), DR["Nombre"].ToString(), DR["Apellido"].ToString(), DR["Telefono"].ToString(), DR["NumeroDocumento"].ToString(), DR["Domicilio"].ToString(), DR["CUIT"].ToString(), DR["CUIL"].ToString() )); } } return _tempClients; }