Hello!
I am using the xamTilemanager to visualize some data. Depending on a property of the displayed data I don not want the user to be able to resize/maximize the tile and I do not want to display the MaximizeButton as on some object of the bound itemsource no further information is found that the user needs.
<ig:XamTileManager ItemsSource="{Binding Directories}" x:Name="DirectoryTiles" > <ig:XamTileManager.Resources> <Style TargetType="{x:Type ig:XamTile}"> <Setter Property="AllowMaximize" Value="{Binding IsDirectory, Converter={StaticResource InvertedBoolToEnabledConverter}}" /> <Setter Property="MaximizeButtonVisibility" Value="{Binding IsDirectory, Converter={StaticResource InvertedBoolToVisibilityConverter}}" /> Style> ig:XamTileManager.Resources>
When I get into the view, I see in the output window the warning that the property "IsDirectory" was not found in my viewModel.
Why is the xamTile referencing to the viewModel and not the bound data item? How can I achieve this functionality?
Edit: Rewrite of thread title
Hello Gergana!
After some other questions I had about the TileManager, I created a custom control that inherits from the tilemanager.
In my control I overrided the "OnTileStateChanging" method. In the method i cast the data from the TileStaeChangingEventArgs.Item and check if a certain property is set. If the condition meets my requirements, I set the TileStateChangingEventArgs.Cancel to true.
Now i do not have to add anystyle or further modifie the tile header.
Thank you for your help
Hello grubarec,
Thank you for your post!
I have been looking into it and it seems that I am missing something from our scenario. Would you please provide me with more detailed information how you bind the XamTile itself?
Having this information would help me further investigate this matter for you.
Looking forward to hearing from you.