Hi,
I need to be able to double click on a carousel item however it needs to follow the mvvm pattern.
Thanks, Grant
Great, thanks! I have no more issues
Thanks for your help
Grant
Hi Grant,
Actually that would be expected. When you change the Theme on the control we're just adding a bunch of resources to the control level. One of these resources is a style for the CarouselBreadcrumb control. So since this style is lower in the tree (closer to the carousel control) than the one I declared in my sample, it will be used instead. To fix that you need to add the style to the XamDataCarousel.Resources. This will place the style lower in the tree making it the one that is used by the CarouselBreadcrumb.
<igDP:XamDataCarousel DataSource="{Binding Source={StaticResource dataUtil}, Path=CategoriesAndProducts}" Theme="Aero"> <igDP:XamDataCarousel.Resources> <Style TargetType="{x:Type igDP:CarouselBreadcrumb}"> <Setter Property="ContentTemplate"> <Setter.Value> <DataTemplate> <TextBlock Text="{Binding Converter={StaticResource converter}}"/> </DataTemplate> </Setter.Value> </Setter> </Style> </igDP:XamDataCarousel.Resources> </igDP:XamDataCarousel>
Thanks for the example. this was actually the very first thing I tried and it didn't work for me. It works in the sample project you sent me however it does not work in my project. I am definitely using the same version of infragistics in my projects. I have even moved across my carousel control onto your sample project and it works.
It has been very frustrating but I have finally seen what the issue was. I was specifying the theme of the carousel as "Aero" in fact I have a combo box where the user can pick their theme and only certain themes work when trying to set the carousel breadcrumb content template. Very weird, unless the items you specify are "Default" or "PrintBasic" then it will not work. So in the example you sent me if you add this then you'll see:
<igDP:XamDataCarousel DataSource="{Binding Source={StaticResource dataUtil},
Path=CategoriesAndProducts}" Theme="Aero" />
Hopefully this can be fixed soon
Looking at the CarouselBreadcrumb control, we're just setting the Content property of this control to a DataRecord. The ToString() on a DataRecord is what shows the text you see. Since we're setting the Content you should be able to provide your own ContentTemplate to change the view. The DataContext for that template will be the CarouselBreadcrumb.Content which is that DataRecord. From there you can use a converter to configure the text however you like. Take a look at the example I attached.
Okay thanks for the answer, wasnt the answer I was hoping for but I can work around it. Another question I have is the breadcrumbs, I can't seem to get the DataRecord word removed from my breadcrumb navigation, I've tried many things but can't seem to get it to work.
It follows on from this post: http://ko.infragistics.com/community/forums/t/27475.aspx
Any ideas on this?