RadCarousel as RowDetail isn't stretching

2 posts, 0 answers
  1. Rafael
    Rafael avatar
    1 posts
    Member since:
    May 2012

    Posted 26 May 2012 Link to this post

    Hi Telerik team, I'm facing a problem of using RadCarousel as RowDetail in a GridView, as the RadCarousel path isn't streching along the row detail, only the RadCarousel background is.

    The result is a big empty blank space from the RadCarousel, and the Carousel itens left-aligned.

    Here is the sample:

    <telerik:RadRibbonWindow
        x:Class="EDAS.MainWindow"
        xmlns:telerikRibbon="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.RibbonView"
        xmlns:i="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity"
        Title="EDAS - Environmental Documentation Alert System"
        Height="640"
        Width="1024"
        WindowStartupLocation="CenterScreen">
     
        <!-- hidded code -->
     
            <telerik:RadGridView Grid.Row="1"
                                 ItemsSource="{Binding Path=Documentos}"
                                 CanUserFreezeColumns="False"
                                 RowIndicatorVisibility="Collapsed"
                                 RowDetailsVisibilityMode="VisibleWhenSelected"
                                 AutoGenerateColumns="False"
                                 x:Name="DocGrid"
                                 IsReadOnly="True"
                                 Visibility="{Binding Path=DocVisibility}">
     
        <!-- hidded code -->
     
                <telerik:RadGridView.RowDetailsTemplate>
                    <DataTemplate>
                        <UserControl>
                            <Grid DataContext="{Binding Path=AnexosContext}">
                                <Grid.RowDefinitions>
                                    <RowDefinition Height="Auto" />
                                    <RowDefinition Height="Auto" />
                                </Grid.RowDefinitions>
                                <Grid.Resources>
                                    <Path x:Key="Horizontal"
                                          Stretch="Fill"
                                          Opacity="1"
                                          Data="M 9,200 C9,200 450,200 450,200 "
                                          Stroke="#FFB4B4B4"
                                          StrokeThickness="1" />
                                </Grid.Resources>
                                <telerik:RadCarousel Grid.Row="0" ItemsSource="{Binding Path=Anexos}" HorizontalScrollBarVisibility="Disabled">
                                    <telerik:RadCarousel.ItemsPanel>
                                        <ItemsPanelTemplate>
                                            <telerik:RadCarouselPanel HorizontalAlignment="Stretch" Path="{StaticResource ResourceKey=Horizontal}" IsContinuous="True" IsPathVisible="True" />
                                        </ItemsPanelTemplate>
                                    </telerik:RadCarousel.ItemsPanel>
                                </telerik:RadCarousel>
                                <StackPanel Grid.Row="1" Orientation="Horizontal" HorizontalAlignment="Center">
                                    <telerik:RadButton Content="Adicionar" Width="75" Command="{Binding Path=AddCommand}" />
                                    <telerik:RadButton Content="Remover" Width="75" Command="{Binding Path=DeleteCommand}" />
                                </StackPanel>
                            </Grid>
                        </UserControl>
                    </DataTemplate>
                </telerik:RadGridView.RowDetailsTemplate>
            </telerik:RadGridView>
    </telerik:RadRibbonWindow>

    Am I missing some configuration?

    Thanks.
  2. Vlad
    Admin
    Vlad avatar
    11100 posts

    Posted 28 May 2012 Link to this post

    Hi,

     I've checked your account however since you do not have any downloads I'm not sure about the version of the grid at your end? Can you post more info?

    Kind regards,
    Vlad
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  3. UI for WPF is Visual Studio 2017 Ready
Back to Top