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

How loading radchart within the template tileview

1 Answer 5 Views
TileView
This is a migrated thread and some comments may be shown as answers.
Ruben
Top achievements
Rank 1
Ruben asked on 28 Mar 2014, 09:45 AM
I'm in need of aid, the Tile View loads the correct items, the ItemSource, but when this TileView in "Large" mode or "Maximizade" I wished he carried a RadChart another ItemSource, but by being within the DataTamplate it does not recognize the other "ObservableCollection" and does not load or c # / code behind knows the name of the RadChart 

Can someone help me or an example of how I do

<
telerik:RadWindow.Resources>
      <DataTemplate x:Key="contentTemplate">
         <telerik:RadFluidContentControl>
              <telerik:RadFluidContentControl.Content>
                        <Grid>
 
                        </Grid>
             <telerik:RadFluidContentControl.Content>
             <telerik:RadFluidContentControl.LargeContent>
               <Grid>
                 <telerik:RadChart x:Name="radChart2"  Margin="0,120,0,0">
                            <telerik:RadChart.SeriesMappings>
                                <telerik:SeriesMapping ItemsSource="{ Binding Path=Series1Items, Mode=TwoWay}">
                                    <telerik:SeriesMapping.SeriesDefinition>
                                        <telerik:LineSeriesDefinition />
                                    </telerik:SeriesMapping.SeriesDefinition>
                                    <telerik:SeriesMapping.ItemMappings>
                                        <telerik:ItemMapping FieldName= "XCat"
                                             DataPointMember="XCategory" />
                                        <telerik:ItemMapping FieldName="YVal"
                                             DataPointMember="YValue" />
                                    </telerik:SeriesMapping.ItemMappings>
                                </telerik:SeriesMapping>
 
                                <telerik:SeriesMapping ItemsSource="{Binding Path=Series2Items, Mode=TwoWay}">
                                    <telerik:SeriesMapping.SeriesDefinition>
                                        <telerik:LineSeriesDefinition />
                                    </telerik:SeriesMapping.SeriesDefinition>
                                    <telerik:SeriesMapping.ItemMappings>
                                        <telerik:ItemMapping FieldName="XCat"
                                             DataPointMember="XCategory" />
                                        <telerik:ItemMapping FieldName="YVal"
                                             DataPointMember="YValue" />
                                    </telerik:SeriesMapping.ItemMappings>
                                </telerik:SeriesMapping>
                            </telerik:RadChart.SeriesMappings>
                            <telerik:RadChart.DefaultView>
                                <telerik:ChartDefaultView>
                                    <telerik:ChartDefaultView.ChartArea>
                                        <telerik:ChartArea>
                                            <telerik:ChartArea.AxisX>
                                                <telerik:AxisX  />
                                            </telerik:ChartArea.AxisX>
                                            <telerik:ChartArea.AxisY>
                                                <telerik:AxisY />
                                            </telerik:ChartArea.AxisY>
                                        </telerik:ChartArea>
                                    </telerik:ChartDefaultView.ChartArea>
                                </telerik:ChartDefaultView>
                            </telerik:RadChart.DefaultView>
                        </telerik:RadChart>
                    </Grid>
                </telerik:RadFluidContentControl.LargeContent>
            </telerik:RadFluidContentControl>
        </DataTemplate>
</telerik:RadWindow.Resources>
 
<Gird>
 <telerik:RadTileView x:Name="list_mon"
                             IsAutoScrollingEnabled="True"
                             MinimizedColumnWidth="150"
                             MinimizedRowHeight="150"
                             RowHeight="260"
                             MaxColumns="2"
                             BorderThickness="0"
                             Padding="0"
                             BorderBrush="Transparent"
                             Background="Transparent"
                             telerik:TileViewPanel.IsVirtualized="True"
                             FontSize="14"
                             FontFamily="Segoe UI"                       
                             Foreground="#FFFFFF"
                             ItemsSource="{Binding ValoresList}"
                             ItemTemplate="{StaticResource headerTemplate}"
                             ContentTemplate="{StaticResource contentTemplate}"
                             TileStateChanged="tileView1_TileStateChanged" Margin="0,88,0,0"   />
</Grid>

1 Answer, 1 is accepted

Sort by
0
Pavel R. Pavlov
Telerik team
answered on 02 Apr 2014, 07:58 AM
Hello Ruben,

I can see that you are using the RadFluidContentControl to switch the content of the RadTileViewItems depending on the state of the items.

However, you need to have in mind that in this case you need to manually change the State property of the RadFluidContentControl. Such approach is demonstrated in this article.
Please take a look at it and let us know if you need any further assistance.

Regards,
Pavel R. Pavlov
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
TileView
Asked by
Ruben
Top achievements
Rank 1
Answers by
Pavel R. Pavlov
Telerik team
Share this question
or