private void comboBoxDevoir_SelectedIndexChanged(object sender, EventArgs e) { eleve EleveSelectionne = listBoxEleve.SelectedItem as eleve; devoir lesDevoirs = comboBoxDevoir.SelectedItem as devoir; DataContextGestionNotesDataContext dc = new DataContextGestionNotesDataContext(); var laNote = (from b in dc.noter where b.id_devoir == lesDevoirs.id_devoir && b.id_eleve == EleveSelectionne.id_eleve select b).ToList(); textBoxNote.Text = " "; if (laNote != null) { foreach (var n in laNote) { textBoxNote.Text = n.note.ToString(); } } }
private void detach_devoir(devoir entity) { this.SendPropertyChanging(); entity.matiere = null; }
private void attach_devoir(devoir entity) { this.SendPropertyChanging(); entity.matiere = this; }
partial void Deletedevoir(devoir instance);
partial void Updatedevoir(devoir instance);
partial void Insertdevoir(devoir instance);