public string Supprimer_fichier(fichier file, bool u) { List <fichier> list = new List <fichier>(); if (!u) { list = file.GetPropritaire().Getlistfilelist(); } if (u) { list = file.GetEmplacement().Getlistoffiles(); } string ok = "your file was deleted !", nok = "you can't !"; int stop = list.Count; if (file.GetDroitacces().Equals("RW")) { list.Remove(file); db.deletefile(file.Getid()); return(ok); } else { return(nok + "you don't have the right "); } }