public VizualizareLectii()
 {
     InitializeComponent();
     lectii = DataAcces.GetLectii();
     listBox1.Items.AddRange(lectii.Select(x => x.NumeImagine.Split('.')[0]).ToArray());
 }