I've been trying to put the items from my list into a combobox by using Data Binding in C#. This is the code i have:

```
ComboBox Name="genreComboBox" DisplayMemberPath="{Binding Name}" SelectedValuePath="{Binding GenreId}"

```

C#

```
IList<Genre> genres = GenreRepository.GetGenres();
genreComboBox.ItemsSource = genres;

```

Im sure that the IList actually gets filled with Genres and that the property Name is correct aswell. When I run this, the combobox gets filled with the .toString() of a Genre. I've tried adding "genreComboBox.DataContext = genres" aswell but this will end up in the combobox getting filled with empty strings.
Any help is appreciated!