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

Tile View shrinks the content - Prism

7 Answers 122 Views
TileView
This is a migrated thread and some comments may be shown as answers.
scorp
Top achievements
Rank 1
scorp asked on 19 Jan 2011, 03:14 PM
Hi is there a way I can show 100% of the content of the control when it is in minimized state.

This is what I have in the shell
  <telerik:RadTileView Name="radTileView1" MaximizeMode="ZeroOrOne" MinimizedItemsPosition="Left">
                        <telerik:RadTileViewItem Header="Region1" Regions:RegionManager.RegionName="Region1"/>
                        <telerik:RadTileViewItem Header="Region2" Regions:RegionManager.RegionName="Region2"/>
                        <telerik:RadTileViewItem Header="Region3" Regions:RegionManager.RegionName="Region3"/>
                    </telerik:RadTileView>
However in the minimized tile view state I would like the tileview to display all of the content and not just a part of it. There needs to be some sort of scaling down as the original page is bigger than what fits into the tile.
Thanks.

7 Answers, 1 is accepted

Sort by
0
scorp
Top achievements
Rank 1
answered on 19 Jan 2011, 05:37 PM
I was able to get 100% content by specifying MaxHeight and MaxWidth properties in my Views instead of explicitly specifying the height and width.
After accomplishing this I came across another issue where when I resize the grid control in which the radTileView resides on minimize and maximize operations in the code behind the animation of the radTileView looks messed up and the tiles are at random positions.
This problem goes away when IsItemsAnimationEnabled is set to "False" however at the cost of losing the animation. 
Thanks.
0
Tina Stancheva
Telerik team
answered on 24 Jan 2011, 11:14 AM
Hello scorp,

Unfortunately, we couldn't reproduce the issue on our side. Therefore I wanted to ask you if you can isolate it in a small project and send it to us so that we can further investigate it.

Thank you in advance.

Regards,
Tina Stancheva
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0
scorp
Top achievements
Rank 1
answered on 24 Jan 2011, 04:38 PM
I have uploaded a small sample project replicating the problem.
https://www.yousendit.com/download/bFlHTG13YTI5bEEwTVE9PQ
0
Accepted
Petar Mladenov
Telerik team
answered on 27 Jan 2011, 01:24 PM
Hello scorp,

Please excuse me for misunderstaing you in my last post ( it`s removed already).
You can use some of the latest control versions (newer than 1220.1040) and Dispatcher like so:
private void myTileView_TilesStateChanged(object sender, Telerik.Windows.RadRoutedEventArgs e)
        {
            RadTileView tileViewItem = e.OriginalSource as RadTileView;
            RadTileViewItem rdItem = tileViewItem.MaximizedItem as RadTileViewItem;
  
            if (rdItem == null)
            {
                MainGrid.Height = 500;
                this.Dispatcher.BeginInvoke(new Action(() =>
                {
                    tileViewItem.UpdateItemsSizeAndPosition();
                }));
            }
            else if (rdItem.TileState == TileViewItemState.Maximized)
            {
                MainGrid.Height = 300;
            }        
        }
Feel free to ask if you need further assistance.


All the best,
Petar Mladenov
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0
scorp
Top achievements
Rank 1
answered on 27 Jan 2011, 03:29 PM
Thanks for the reply. This seems to have corrected almost all issues except I get this exception message frequently while minimizing and maximizing:
Microsoft JScript runtime error: Unhandled Error in Silverlight Application 
Code: 4004    
Category: ManagedRuntimeError       
Message: System.Windows.LayoutCycleException: Layout cycle detected.  Layout could not complete.
   at MS.Internal.XcpImports.MethodEx(IntPtr ptr, String name, CValue[] cvData)
   at MS.Internal.XcpImports.MethodEx(DependencyObject obj, String name)
   at System.Windows.UIElement.UpdateLayout()
   at Telerik.Windows.Controls.RadTileView.DetermineScrollBarVisibility(RadTileViewItem maximizedItem)
   at Telerik.Windows.Controls.RadTileView.<UpdateScrollBar>b__58()     


I am using version 2010.3.1110.1040
Is there any version newer than this and if that would resolve the issue.
0
Petar Mladenov
Telerik team
answered on 28 Jan 2011, 04:48 PM
Hello scorp,

We are unable to reproduce the issue you have described using the 1110.1040 version of the dlls. Could you please examine the attached project and let us know if we are missing something? You can modify it, or you can send us another sample showing the issue. You can also send us a video. Thank you for your cooperation.

Regards,
Petar Mladenov
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0
scorp
Top achievements
Rank 1
answered on 01 Feb 2011, 03:54 PM
I am unable to recreate the problem after I restarted my computer recently. Will let you know if I come across the same problem again.

2/3/2011:
I was able to recreate the issue however I tried the workaround as mentioned on this post and the problem went away.
http://www.telerik.com/community/forums/silverlight/tileview/layoutcycleexception-with-radcharts.aspx
Tags
TileView
Asked by
scorp
Top achievements
Rank 1
Answers by
scorp
Top achievements
Rank 1
Tina Stancheva
Telerik team
Petar Mladenov
Telerik team
Share this question
or