Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class Cliente
- {
- public string ID { get; set; }
- public string Nome { get; set; }
- public string CPF { get; set; }
- public string Email { get; set; }
- public string Base { get; set; }
- public bool Enviado { get; set; }
- public Cliente(string id, string nome, string cpf, string email, string baseDados = "TV", bool enviado = false)
- {
- ID = id;
- Nome = nome;
- CPF = cpf;
- Email = email;
- Enviado = enviado;
- Base = baseDados;
- }
- }
- List<Cliente> clientes = new List<Cliente>();
- Cliente c = clientes.Select(x => x.Enviado == false);
- Cliente c = clientes.FirstOrDefault(x => !x.Enviado);
- Cliente c = clientes.Where(x => x.Enviado == false).FirstOrDefault();
Add Comment
Please, Sign In to add comment