c# - Flyout not showing for buttons inside ItemTemplate -



c# - Flyout not showing for buttons inside ItemTemplate -

i trying show flyout whenever user presses button within listbox have created. here code used load bind item source , attach flyout.

<mycontrols:mylistbox itemssource="{binding mylist}"> <mycontrols:mylistbox.itemtemplate> <datatemplate> <grid> <grid.rowdefinitions> <rowdefinition height="auto"/> </grid.rowdefinitions> <grid.columndefinitions> <columndefinition/> <columndefinition width="70" /> </grid.columndefinitions> <textblock grid.column="0" text="{binding path=myfield}"></textblock> <button loaded="deletebutton_onloaded" click="ondeleteconfirmationclick" flyout="{staticresource myflyout}" grid.column ="1""></button> </grid> </datatemplate> </mycontrols:mylistbox.itemtemplate> </mycontrols:mylistbox>

here code flyout static resource.

<page.resources> <flyout x:key="myflyout"> <stackpanel> <textblock>some confirmation message</textblock> <button></button> </stackpanel> </flyout> </page.resources>

i receiving onloaded event every button both click , flyout not beingness fired. have buttons beingness within itemtemplate?

when have event based object in template need reach outside of items events declaration of clickmode in instance illustration adding clickmode="press" button allow detach , handle own events.

since sits, have have item selected button sits in in order click handled.

not sure if that's technically sound explanation concept correct, , glad got remedy. cheers!

c# visual-studio-2013 winrt-xaml windows-applications

Comments

Popular posts from this blog

php - Android app custom user registration and login with cookie using facebook sdk -

django - Access session in user model .save() -

php - .htaccess Multiple Rewrite Rules / Prioritizing -