private Guid FindEtat(EntiteEnum employe, string libelle) { var etat = Contexte.Etats.FirstOrDefault(e => e.Entite == (byte)employe && e.Libelle == libelle); if (etat == null) { return(default);
public Guid FindEtat(EntiteEnum entite, string libelle) { Cmd.CommandText = $"SELECT Id FROM Etat WHERE Entite = {(int)entite} and Libelle = '{libelle}' "; try { return((Guid)Cmd.ExecuteScalar()); } catch (Exception e) { Console.Write(e); return(default);