private void SaveChanges(object sender, EventArgs e) { var nameOfPublisher = nameOfPublisherTextBox.Text; var selectedBooks = booksCheckedListBox.CheckedItems; var isSaved = _publishersRepository.AddOrEditAPublisher(nameOfPublisher, selectedBooks, _publisher.PublisherId); if (!isSaved) { MessageBox.Show("Pogreska pri unosu. Sva polja moraju imati sadrzaj!", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); } else { MessageBox.Show("Izdavac uspjesno spremljen!", "Message", MessageBoxButtons.OK, MessageBoxIcon.Information); Close(); } }