Dear infragistics team
I'm new to infragistics Silverlight controls and would like to use them in my project but have issue with persisting XamTileManager layout with PersistenceManager, the main issue is that "layout is not being persisted.
Below is example to reproduce it, also notice that if I remove TileLayoutOrder="UseExplicitRowColumnOnTile" attribute declaration then the XamTileManager layout is persisted, but I need the persistence to work with that attribute
Xaml :
<ig:XamTileManager x:Name="tileManager" ItemsSource="{Binding Panels}">
<ig:XamTileManager.NormalModeSettings>
<ig:NormalModeSettings TileLayoutOrder="UseExplicitRowColumnOnTile"/>
</ig:XamTileManager.NormalModeSettings>
</ig:XamTileManager>
Code behind:
void MainPage_Loaded(object sender, RoutedEventArgs e)
{
this.DataContext = new ViewModel();
}
private void btnSave_Click(object sender, System.Windows.RoutedEventArgs e)
var memStream = PersistenceManager.Save(tileManager);
FileStream fs = new FileStream(@"D:\LayoutState.dat", FileMode.Create);
fs.Write(memStream.ToArray(), 0, (int)memStream.Length);
fs.Close();
private void btnLoad_Click(object sender, System.Windows.RoutedEventArgs e)
if (File.Exists(@"D:\manState.dat"))
FileStream fs = new FileStream(@"D:\ LayoutState.dat", FileMode.Open);
PersistenceManager.Load(tileManager, fs);
ViewModel class:
public class ViewModel
public ViewModel()
this.Panels = new ObservableCollection<PanelModel>();
this.Panels.Add(new PanelModel() { Title = "Tile Item 1" });
public ObservableCollection<PanelModel> Panels {get;set;}
Thanks in advance
Xusan
Hello Xusan,
I found this post duplicate to this one:
http://community.infragistics.com/forums/t/69156.aspx
which is already discussed.