We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Getting item reference after when generated from datatemplate

I have tried the SampleBrowser project in samples folder which we get after syncfusionessentialwinrt msi  package installation. I see the items in SfTileView are generated via data template defined  in location "C:\\~\AppData\Local\Syncfusion\EssentialStudio\12.3.0.36\Universal\SampleBrowser\SampleBrowser\SampleBrowser.Shared\TileView\View". Whenever   I click on item I want to suppress the default behaviour that is after clicking the item I want to suppress the maximize behaviour and  redirect to other page . I was able to do so by  attaching StateChanged event handler and  redirect to other page in my project according to tag of the clicked item. Previously I added items from Code behind file and was able to bind Tapped event handler and StateChanged event handler and was successfully able to redirect to other page instead of item getting maximized.  Now when I generate items via DataTemplate I am not getting the items .  I want to get the reference for each item and bind them to StateChanged event handler and  Tapped event handler to redirect to other page (write my custom logic ).  I am not being able to do so. Is there any built in feature provided in the product to achieve this requirement . Can   i get any help from your side ? I am hoping for q

1 Reply

BK Bharadhi K Syncfusion Team December 16, 2014 09:20 AM UTC

Hi Suresh,

Thank you for using Syncfusion products.

Query: when I generate items via DataTemplate I am not getting the items .

We have prepared a sample in which we have tried to meet your requirements. In our sample we have generated the SfTileViewItems through a DataTemplate and have binded a property "TestCommand" to the Command property of the SfHubTile in the DataTemplate. Using this property we can get an object of the SfTileViewItem as a parameter. Please find the sample in the following link.

Please let us know if you required any further assistance on this.

Regards,
Bharadhi K


Attachment: SfTileview_133108_9e07c5ed.zip

Loader.
Live Chat Icon For mobile
Up arrow icon