This is a migrated thread and some comments may be shown as answers.

Images is not displayed

1 Answer 49 Views
Carousel
This is a migrated thread and some comments may be shown as answers.
Magnus Modig
Top achievements
Rank 1
Magnus Modig asked on 27 Mar 2009, 08:02 AM
Hi

I have a carousel that is filled with a list of images like this..

Dim MyListOfImages As New List(Of _Images)

 

MyListOfImages.Add( .....



RadCarousel1.ItemsSource = MyListOfImages

But there are no images displayed, only images with the current image path. Why is that, and how do I fix this?

1 Answer, 1 is accepted

Sort by
0
Hristo Deshev
Telerik team
answered on 27 Mar 2009, 05:07 PM
Hello Magnus Modig,

I just answered your question in the support ticket you opened. I am posting it here just in case somebody has the same problem.

The ListOfImages turned out to contain file paths. The best way to display the images is to modify the CarouselItem template with a style similar to the one below:

<telerik:RadCarousel.Resources> 
    <Style TargetType="telerik:CarouselItem"
        <Setter Property="Template"
            <Setter.Value> 
                <ControlTemplate TargetType="telerik:CarouselItem"
                    <Image Source="{Binding Data.FileName}"></Image> 
                </ControlTemplate> 
            </Setter.Value> 
        </Setter> 
    </Style>    
</telerik:RadCarousel.Resources> 
 


Regards,
Hristo Deshev
the Telerik team

Check out Telerik Trainer , the state of the art learning tool for Telerik products.
Tags
Carousel
Asked by
Magnus Modig
Top achievements
Rank 1
Answers by
Hristo Deshev
Telerik team
Share this question
or