Thanks for the sample, it actually clarified another non related problem I was working on! LOL
Sadly, however I am still having issues, with the collection not updating when I add a photo to the list.
Pseudo code.
public void async Take picture()
{
...Do camera stuff...
Photos image = new Photos();
image.name = camerastuff.filename;
image.source = byte[]Image;
image.path = camerastuff.pathtoimage;
image.category = (int)enuCategory.Ocilloscope;
// Add the image object to the database.
await PhotoRepository.AddItem(image).ConfigureAwait(false);
// Clear the images list.
lPhotos.Clear();
// repopulate the list with the images from the database.
lPhotos = new ObservableCollection
(await PhotoRepo.GetItemByParentID((int)ParentId, (int)enuCategory.Ocilloscope).ConfigureAwait(true));
//Refesh the carousel with the list of images.
carousel.ItemsSource = lPhotos;
carousel.DisplayMemberPath = "path";
}
The above code never updates the list of carousel images. I've also tried doing it in a number of other ways. I've tried just adding the image to my list lPhotos, hoping the carousel would automatically detect the added item, I've tried updating the carousel directly form the database, (performing the repository GetItemByParentID call directly into the ItemsSource).
Is there any method I can call to force the carousel to update it's view, or re-enumerate it's list?
Thanks again!